nx.js
Variables

kNativeFileSource

const kNativeFileSource: typeof kNativeFileSource

Internal tags enabling a transparent native fast path for the file.stream().pipeThrough(new DecompressionStream(fmt)) pattern.

FsFile.stream() tags its ReadableStream with kNativeFileSource carrying { path, start, end }. DecompressionStream tags itself with kNativeDecompressSetup — a factory that, given such a descriptor, returns a ReadableStream driven by the fused native read+decompress op. The ReadableStream.prototype.pipeThrough override below detects the combination and bypasses the polyfill pipeTo machinery (which otherwise allocates ~10 promises + several ArrayBuffers per chunk and amplifies peak memory) entirely. Any other source/transform pair falls through to the normal polyfill pipe.