Home / Function/ processIfConditions() — vue Function Reference

processIfConditions() — vue Function Reference

Architecture documentation for the processIfConditions() function in index.ts from the vue codebase.

Entity Profile

Dependency Diagram

graph TD
  f819e82d_0c73_4842_095d_5d0adae6ddd9["processIfConditions()"]
  bbf88914_62b5_839d_3cfb_85a00fd1d67b["parse()"]
  bbf88914_62b5_839d_3cfb_85a00fd1d67b -->|calls| f819e82d_0c73_4842_095d_5d0adae6ddd9
  802eec95_917b_07e2_b5ac_340967118c72["findPrevElement()"]
  f819e82d_0c73_4842_095d_5d0adae6ddd9 -->|calls| 802eec95_917b_07e2_b5ac_340967118c72
  a43ff6ef_b3eb_ea6c_cf0e_7fea2e444821["addIfCondition()"]
  f819e82d_0c73_4842_095d_5d0adae6ddd9 -->|calls| a43ff6ef_b3eb_ea6c_cf0e_7fea2e444821
  style f819e82d_0c73_4842_095d_5d0adae6ddd9 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

src/compiler/parser/index.ts lines 567–581

function processIfConditions(el, parent) {
  const prev = findPrevElement(parent.children)
  if (prev && prev.if) {
    addIfCondition(prev, {
      exp: el.elseif,
      block: el
    })
  } else if (__DEV__) {
    warn(
      `v-${el.elseif ? 'else-if="' + el.elseif + '"' : 'else'} ` +
        `used on element <${el.tag}> without corresponding v-if.`,
      el.rawAttrsMap[el.elseif ? 'v-else-if' : 'v-else']
    )
  }
}

Domain

Subdomains

Called By

Frequently Asked Questions

What does processIfConditions() do?
processIfConditions() is a function in the vue codebase.
What does processIfConditions() call?
processIfConditions() calls 2 function(s): addIfCondition, findPrevElement.
What calls processIfConditions()?
processIfConditions() is called by 1 function(s): parse.

Analyze Your Own Codebase

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

Try Supermodel Free