genProps() — vue Function Reference
Architecture documentation for the genProps() function in index.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 8d77643c_f644_5b38_7cc9_470546920393["genProps()"] 37199ba4_dbb1_d3e4_1b99_701b07750519["genData()"] 37199ba4_dbb1_d3e4_1b99_701b07750519 -->|calls| 8d77643c_f644_5b38_7cc9_470546920393 42bea0e4_d68e_8c1a_27b1_d90fdcd8e88d["genSlot()"] 42bea0e4_d68e_8c1a_27b1_d90fdcd8e88d -->|calls| 8d77643c_f644_5b38_7cc9_470546920393 55a5def2_0aa8_b39b_8af6_e1624809e5dc["transformSpecialNewlines()"] 8d77643c_f644_5b38_7cc9_470546920393 -->|calls| 55a5def2_0aa8_b39b_8af6_e1624809e5dc style 8d77643c_f644_5b38_7cc9_470546920393 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
src/compiler/codegen/index.ts lines 645–663
function genProps(props: Array<ASTAttr>): string {
let staticProps = ``
let dynamicProps = ``
for (let i = 0; i < props.length; i++) {
const prop = props[i]
const value = transformSpecialNewlines(prop.value)
if (prop.dynamic) {
dynamicProps += `${prop.name},${value},`
} else {
staticProps += `"${prop.name}":${value},`
}
}
staticProps = `{${staticProps.slice(0, -1)}}`
if (dynamicProps) {
return `_d(${staticProps},[${dynamicProps.slice(0, -1)}])`
} else {
return staticProps
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does genProps() do?
genProps() is a function in the vue codebase.
What does genProps() call?
genProps() calls 1 function(s): transformSpecialNewlines.
What calls genProps()?
genProps() is called by 2 function(s): genData, genSlot.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free