Skip to content

Overhaul and update project #11

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 28 commits into from
Mar 16, 2022
Merged

Overhaul and update project #11

merged 28 commits into from
Mar 16, 2022

Conversation

basicdays
Copy link
Owner

@basicdays basicdays commented Mar 15, 2022

  • Breaking Change: Dropping support for Node 11 and below.
  • Breaking Change: Dropping support for Flow.
  • Bug Fix: Resolves End handlers not being removed after next resolve #5. Event handlers are cleaned up after each iteration, fixing some memory leak issues.
  • Bug Fix: Resolves Emitted code uses regeneratorRuntime #7. Code no longer depends on babel runtimes or regenerator.
  • Bug Fix: Handles stream not buffering due to starving the event loop.
  • Feature: Resolves Add .throw and .return interface methods to StreamToAsyncIterator #1. Now handles .throw and .return hooks on the async iterator.
  • Feature: Properly closes stream when finished.
  • Feature: Added support for TypeScript.
  • Feature: Support for Node.js versions 12, 14, and 16.
  • Chore: General overhaul of project setup (should not impact what is published).

@basicdays basicdays changed the title Ps/overhaul Overhaul and update project Mar 15, 2022
@basicdays basicdays changed the base branch from develop to master March 15, 2022 23:37
@basicdays basicdays marked this pull request as ready for review March 16, 2022 17:05
@basicdays basicdays changed the base branch from master to develop March 16, 2022 17:10
@basicdays basicdays changed the base branch from develop to master March 16, 2022 17:10
@basicdays basicdays force-pushed the ps/overhaul branch 2 times, most recently from ece3fd7 to faff23f Compare March 16, 2022 17:14
@basicdays basicdays merged commit 3b1f109 into master Mar 16, 2022
@basicdays basicdays deleted the ps/overhaul branch March 16, 2022 21:11
@LinusU
Copy link

LinusU commented Mar 17, 2022

Breaking Change: Dropping support for Node 11 and below.

Not sure if you are aware, but in Node 12+ the Readable stream implements asyncIterator already:

#!/usr/bin/env node
"use strict";
const { Readable } = require("stream");

(async function () {
    const readStream = Readable.from([1, 2, 3]);
    for await (const chunk of readStream) {
        console.dir({ chunk });
    }
})();

@basicdays
Copy link
Owner Author

@LinusU It was more an attempt to get this to wrap around a db driver module that used an instance of Readable that they somehow made themselves. No luck unfortunately, but did all this work, figured I'd just as well publish it anyways. I should probably move the node support to legacy though so that it might be useful on very legacy projects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants