_read() — vue Function Reference
Architecture documentation for the _read() function in render-stream.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 26f93250_b4a7_4186_f2ca_6e7705f6c0d6["_read()"] 60ba4fed_c502_859c_60b1_5ab9b57882ca["RenderStream"] 26f93250_b4a7_4186_f2ca_6e7705f6c0d6 -->|defined in| 60ba4fed_c502_859c_60b1_5ab9b57882ca 9142a816_c281_34f1_d187_c42a71e9ebc2["pushBySize()"] 26f93250_b4a7_4186_f2ca_6e7705f6c0d6 -->|calls| 9142a816_c281_34f1_d187_c42a71e9ebc2 5424efdc_7dd2_a107_0b02_df960b12b9bb["tryRender()"] 26f93250_b4a7_4186_f2ca_6e7705f6c0d6 -->|calls| 5424efdc_7dd2_a107_0b02_df960b12b9bb f1eef107_ac43_15e5_0802_999cd0990503["tryNext()"] 26f93250_b4a7_4186_f2ca_6e7705f6c0d6 -->|calls| f1eef107_ac43_15e5_0802_999cd0990503 style 26f93250_b4a7_4186_f2ca_6e7705f6c0d6 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
packages/server-renderer/src/render-stream.ts lines 79–99
_read(n: number) {
this.expectedSize = n
// it's possible that the last chunk added bumped the buffer up to > 2 * n,
// which means we will need to go through multiple read calls to drain it
// down to < n.
if (isTrue(this.done)) {
this.push(null)
return
}
if (this.buffer.length >= n) {
this.pushBySize(n)
return
}
if (isUndef(this.next)) {
// start the rendering chain.
this.tryRender()
} else {
// continue with the rendering.
this.tryNext()
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does _read() do?
_read() is a function in the vue codebase, defined in packages/server-renderer/src/render-stream.ts.
Where is _read() defined?
_read() is defined in packages/server-renderer/src/render-stream.ts at line 79.
What does _read() call?
_read() calls 3 function(s): pushBySize, tryNext, tryRender.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free