049bb22c1c
* attach pipeTo and pipeThrough polyfills to instance * remove transformer polyfill * remove polyfill * fix missing polyfill in sandbox * always polyfill the runtime * always polyfill web streams in renderer * fix missing AbortController and AbortSignal * type fix * fix type generation * use global Co-authored-by: Shu Ding <shu@shus-mac-studio.localdomain>
12 lines
294 B
JavaScript
12 lines
294 B
JavaScript
import {
|
|
ReadableStream,
|
|
TransformStream,
|
|
} from 'next/dist/compiled/web-streams-polyfill'
|
|
|
|
// Polyfill Web Streams for the Node.js runtime.
|
|
if (!global.ReadableStream) {
|
|
global.ReadableStream = ReadableStream
|
|
}
|
|
if (!global.TransformStream) {
|
|
global.TransformStream = TransformStream
|
|
}
|