A utility method for creating duplex streams.
Stream converts writable stream into writable Duplex and readable stream to Duplex.Blob converts into readable Duplex.string converts into readable Duplex.ArrayBuffer converts into readable Duplex.AsyncIterable converts into a readable Duplex. Cannot yield null.AsyncGeneratorFunction converts into a readable/writable transform Duplex. Must take a source AsyncIterable as first parameter. Cannot yield null.AsyncFunction converts into a writable Duplex. Must return either null or undefinedObject ({ writable, readable }) converts readable and writable into Stream and then combines them into Duplex where the Duplex will write to the writable and read from the readable.Promise converts into readable Duplex. Value null is ignored.
ZstdDecompress.from method | Node.js zlib module | Bun BuildDocsReferenceGuidesBlogDiscord/node:zlib/ZstdDecompress/fromMfrom BuildDocsReferenceGuidesBlogDiscord /node:zlib/ZstdDecompress/fromMfrom zlib.ZstdDecompress.fromstatic from(src: string | Blob | Promiseany> | ReadableStream | WritableStream | Iterableany, any, any> | AsyncIterableany, any, any> | (source: AsyncIterableany>) => AsyncIterableany> | (source: AsyncIterableany>) => Promisevoid> | ReadableWritablePairany, any> | ReadableStreamany> | WritableStreamany>): Duplex; Referenced typesinterface Blobreadonly size: numberreadonly type: stringarrayBuffer(): PromiseArrayBuffer>; bytes(): PromiseNonSharedUint8Array>;bytes(): PromiseUint8ArrayArrayBuffer>>; slice(start?: number,end?: number,contentType?: string): Blob;stream(): ReadableStreamNonSharedUint8Array>;stream(): ReadableStreamUint8ArrayArrayBuffer>>; text(): Promisestring>;interface ReadableWritablePairR = any, W = any>readable: ReadableStreamR>writable: WritableStreamW>interface ReadableStreamR = any>readonly locked: booleancancel(reason?: any): Promisevoid>;getReader(options: { mode: 'byob' }): ReadableStreamBYOBReader;getReader(): ReadableStreamDefaultReaderR>;getReader(options?: ReadableStreamGetReaderOptions): ReadableStreamReaderR>;pipeThroughT>(transform: ReadableWritablePairT, R>,options?: StreamPipeOptions): ReadableStreamT>;pipeTo(destination: WritableStreamR>,options?: StreamPipeOptions): Promisevoid>;tee(): [ReadableStreamR>, ReadableStreamR>];values(options?: ReadableStreamIteratorOptions): ReadableStreamAsyncIteratorR>;interface WritableStreamW = any>readonly locked: booleanabort(reason?: any): Promisevoid>;close(): Promisevoid>;getWriter(): WritableStreamDefaultWriterW>;
Search the reference...
/
method
Consume the blob as an ArrayBuffer
Consume as a Uint8Array, backed by an ArrayBuffer
Returns a readable stream of the blob's contents
Resources
ReferenceDocsGuidesDiscordMerch StoreGitHubBlogToolkit
RuntimePackage managerTest runnerBundlerPackage runnerProject
Bun 1.0Bun 1.1Bun 1.2Bun 1.3RoadmapContributingLicenseBaked with ❤️ in San Francisco
We're hiring →ZstdDecompress.from method | Node.js zlib module | Bun,AI智能索引,全网链接索引,智能导航,网页索引
- API documentation for method node:zlib.ZstdDecompress.from | Bun