_read() — vue Function Reference
Architecture documentation for the _read() function in render-stream.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd["_read()"] 3d417805_fdc5_389c_85fe_d5ccc2aa023a["pushBySize()"] 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd -->|calls| 3d417805_fdc5_389c_85fe_d5ccc2aa023a c12a387b_45bc_4e46_392d_05ec98b186bc["tryRender()"] 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd -->|calls| c12a387b_45bc_4e46_392d_05ec98b186bc 3950fa28_ada6_cd2c_19ca_d9761d2c1331["tryNext()"] 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd -->|calls| 3950fa28_ada6_cd2c_19ca_d9761d2c1331 c0051429_b95b_daa0_fc77_989c8344497d["isTrue()"] 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd -->|calls| c0051429_b95b_daa0_fc77_989c8344497d 299f2646_f776_9b7d_1179_7b9087b1e66c["isUndef()"] 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd -->|calls| 299f2646_f776_9b7d_1179_7b9087b1e66c style 5dc11fa1_4fde_c7b7_e1fd_54a1954c09fd 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.
What does _read() call?
_read() calls 5 function(s): isTrue, isUndef, pushBySize, tryNext, tryRender.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free