Skip to content
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

Add subscription mechanism using async iterators #40

Merged
merged 21 commits into from Sep 17, 2019
Merged

Add subscription mechanism using async iterators #40

merged 21 commits into from Sep 17, 2019

Conversation

lorenzofox3
Copy link
Contributor

The follow up of the previous pull request rebaseing the code base

@lorenzofox3
Copy link
Contributor Author

Note: users should probably be warned that this (anti)pattern would eventually lead to memory leak:
event emitter is pushed based whereas async iterator is pull based so if the subscriber is slower to process than the emitter to emit the internal queue will keep growing.

readme.md Outdated Show resolved Hide resolved
@sindresorhus
Copy link
Owner

You need to update https://github.com/sindresorhus/emittery/blob/master/index.d.ts too (The text should be the same as the readme, including examples).

@sindresorhus sindresorhus changed the title Implements subscricption mechanism using async iterators protocol Implements subscription mechanism using async iterators Jun 23, 2019
@sindresorhus sindresorhus changed the title Implements subscription mechanism using async iterators Add subscription mechanism using async iterators Jun 23, 2019
@sindresorhus
Copy link
Owner

You need to update /index.d.ts@master too (The text should be the same as the readme, including examples).

@lorenzofox3 ⬆️ :)

@lorenzofox3
Copy link
Contributor Author

oops my bad I had not seen that one :)

@sindresorhus sindresorhus merged commit 2baf580 into sindresorhus:master Sep 17, 2019
@sindresorhus
Copy link
Owner

Thanks for working on this, @lorenzofox3 🙌

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

Successfully merging this pull request may close these issues.

None yet

3 participants