Vercel has developed a library called `fast-webstreams` that reimplements the WHATWG `ReadableStream`, `WritableStream`, and `TransformStream` APIs using Node.js streams internally. This library significantly improves performance for common operations like piping between streams, chunk-by-chunk reading, and handling React Server Component byte streams. The library aims to reduce Promise and object allocation overhead, leading to substantial speedups in server-side rendering and data processing. This work is being contributed upstream to Node.js.
All Vercel trails