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

Error when importing in Node.js #33

Closed
Richienb opened this issue Jan 27, 2021 · 1 comment
Closed

Error when importing in Node.js #33

Richienb opened this issue Jan 27, 2021 · 1 comment

Comments

@Richienb
Copy link
Contributor

Since Node.js doesn't support top-level await, this code throws when imported:

globalThis.ReadableStream = await import('web-streams-polyfill/ponyfill/es2018');

@sindresorhus
Copy link
Owner

Node.js 14 does support top-level await: https://twitter.com/codebytere/status/1293229801570881537

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

No branches or pull requests

2 participants