doc: clarify description of readable.push()
method
PR-URL: https://github.com/nodejs/node/pull/29687 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Beth Griggs <Bethany.Griggs@uk.ibm.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
This commit is contained in:
parent
7223ce2a9c
commit
63c0f15a82
@ -2148,8 +2148,8 @@ class SourceWrapper extends Readable {
|
|||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
The `readable.push()` method is intended be called only by `Readable`
|
The `readable.push()` method is used to push the content
|
||||||
implementers, and only from within the `readable._read()` method.
|
into the internal buffer. It can be driven by the `readable._read()` method.
|
||||||
|
|
||||||
For streams not operating in object mode, if the `chunk` parameter of
|
For streams not operating in object mode, if the `chunk` parameter of
|
||||||
`readable.push()` is `undefined`, it will be treated as empty string or
|
`readable.push()` is `undefined`, it will be treated as empty string or
|
||||||
|
Loading…
x
Reference in New Issue
Block a user