checkForAliasModel() — vue Function Reference
Architecture documentation for the checkForAliasModel() function in index.ts from the vue codebase.
Entity Profile
Dependency Diagram
graph TD 933c2dfe_2a12_48de_3a97_4aec1fcd7fca["checkForAliasModel()"] 101d3d34_ac07_228f_62b9_5d5ac4a0ea2e["index.ts"] 933c2dfe_2a12_48de_3a97_4aec1fcd7fca -->|defined in| 101d3d34_ac07_228f_62b9_5d5ac4a0ea2e 89ae2d84_ca61_4847_7313_0974c1948730["processAttrs()"] 89ae2d84_ca61_4847_7313_0974c1948730 -->|calls| 933c2dfe_2a12_48de_3a97_4aec1fcd7fca style 933c2dfe_2a12_48de_3a97_4aec1fcd7fca fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
src/compiler/parser/index.ts lines 984–999
function checkForAliasModel(el, value) {
let _el = el
while (_el) {
if (_el.for && _el.alias === value) {
warn(
`<${el.tag} v-model="${value}">: ` +
`You are binding v-model directly to a v-for iteration alias. ` +
`This will not be able to modify the v-for source array because ` +
`writing to the alias is like modifying a function local variable. ` +
`Consider using an array of objects and use v-model on an object property instead.`,
el.rawAttrsMap['v-model']
)
}
_el = _el.parent
}
}
Domain
Subdomains
Defined In
Called By
Source
Frequently Asked Questions
What does checkForAliasModel() do?
checkForAliasModel() is a function in the vue codebase, defined in src/compiler/parser/index.ts.
Where is checkForAliasModel() defined?
checkForAliasModel() is defined in src/compiler/parser/index.ts at line 984.
What calls checkForAliasModel()?
checkForAliasModel() is called by 1 function(s): processAttrs.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free