To convert a Buffer into a ReadableStream in Node.js, we call the Readable.from method.
For instance, we write
const { Readable } = require("stream");
const stream = Readable.from(myBuffer);
to call Readable.from to convert the myBuffer to a readable stream.
This is avilable from Node.js 10.17.0 and up.