Home / Function/ genRadioModel() — vue Function Reference

genRadioModel() — vue Function Reference

Architecture documentation for the genRadioModel() function in model.ts from the vue codebase.

Entity Profile

Dependency Diagram

graph TD
  dc49a23f_3673_17c2_d4ff_83744ff5f5a2["genRadioModel()"]
  f36954a8_e8f3_1232_73cb_dd1434e32bc1["model()"]
  f36954a8_e8f3_1232_73cb_dd1434e32bc1 -->|calls| dc49a23f_3673_17c2_d4ff_83744ff5f5a2
  0d1a9a6d_9f27_26ff_a82e_63f0ab50e4ee["getBindingAttr()"]
  dc49a23f_3673_17c2_d4ff_83744ff5f5a2 -->|calls| 0d1a9a6d_9f27_26ff_a82e_63f0ab50e4ee
  4daec7f5_cb46_f8e0_ce45_d7c464826c5d["addProp()"]
  dc49a23f_3673_17c2_d4ff_83744ff5f5a2 -->|calls| 4daec7f5_cb46_f8e0_ce45_d7c464826c5d
  5f7b1ed1_7106_20e8_83d2_d329e3f4a814["addHandler()"]
  dc49a23f_3673_17c2_d4ff_83744ff5f5a2 -->|calls| 5f7b1ed1_7106_20e8_83d2_d329e3f4a814
  36fcfc37_216e_9f34_5a69_e976b9f178f6["genAssignmentCode()"]
  dc49a23f_3673_17c2_d4ff_83744ff5f5a2 -->|calls| 36fcfc37_216e_9f34_5a69_e976b9f178f6
  style dc49a23f_3673_17c2_d4ff_83744ff5f5a2 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

src/platforms/web/compiler/directives/model.ts lines 107–117

function genRadioModel(
  el: ASTElement,
  value: string,
  modifiers?: ASTModifiers | null
) {
  const number = modifiers && modifiers.number
  let valueBinding = getBindingAttr(el, 'value') || 'null'
  valueBinding = number ? `_n(${valueBinding})` : valueBinding
  addProp(el, 'checked', `_q(${value},${valueBinding})`)
  addHandler(el, 'change', genAssignmentCode(value, valueBinding), null, true)
}

Domain

Subdomains

Called By

Frequently Asked Questions

What does genRadioModel() do?
genRadioModel() is a function in the vue codebase.
What does genRadioModel() call?
genRadioModel() calls 4 function(s): addHandler, addProp, genAssignmentCode, getBindingAttr.
What calls genRadioModel()?
genRadioModel() is called by 1 function(s): model.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free