MCPcopy Index your code
hub / github.com/nodejs/node / streamToAsyncIterator

Function streamToAsyncIterator

lib/internal/streams/readable.js:1373–1381  ·  view source on GitHub ↗
(stream, options)

Source from the content-addressed store, hash-verified

1371};
1372
1373function streamToAsyncIterator(stream, options) {
1374 if (typeof stream.read !== 'function') {
1375 stream = Readable.wrap(stream, { objectMode: true });
1376 }
1377
1378 const iter = createAsyncIterator(stream, options);
1379 iter.stream = stream;
1380 return iter;
1381}
1382
1383async function* createAsyncIterator(stream, options) {
1384 let callback = nop;

Callers 1

readable.jsFile · 0.85

Calls 2

createAsyncIteratorFunction · 0.85
wrapMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…