File tree Expand file tree Collapse file tree 3 files changed +3
-2
lines changed Expand file tree Collapse file tree 3 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,7 @@ project adheres to [Semantic Versioning](http://semver.org/).
1818- Run test WPT test against our impl [ #109 ]
1919- File name are now casted to string [ #109 ]
2020- Slicing in the middle of multiple parts added more bytes than what what it should have [ #109 ]
21+ - Prefixed ` stream/web ` import with ` node: ` to allow easier static analysis detection of Node built-ins [ #122 ]
2122
2223## v3.1.2
2324
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ const POOL_SIZE = 65536;
44
55if ( ! globalThis . ReadableStream ) {
66 try {
7- Object . assign ( globalThis , require ( 'stream/web' ) )
7+ Object . assign ( globalThis , require ( 'node: stream/web' ) )
88 } catch ( error ) {
99 // TODO: Remove when only supporting node >= 16.5.0
1010 Object . assign ( globalThis , require ( 'web-streams-polyfill/dist/ponyfill.es2018.js' ) )
Original file line number Diff line number Diff line change @@ -390,7 +390,7 @@ test('returns a readable stream', t => {
390390
391391test ( 'checking instanceof blob#stream' , async t => {
392392 // eslint-disable-next-line node/no-unsupported-features/es-syntax
393- const { ReadableStream} = await import ( 'stream/web' ) . catch ( _ => import ( 'web-streams-polyfill/dist/ponyfill.es2018.js' ) ) ;
393+ const { ReadableStream} = await import ( 'node: stream/web' ) . catch ( _ => import ( 'web-streams-polyfill/dist/ponyfill.es2018.js' ) ) ;
394394 const stream = new File ( [ ] , '' ) . stream ( ) ;
395395 t . true ( stream instanceof ReadableStream ) ;
396396} ) ;
You can’t perform that action at this time.
0 commit comments