Home / Function/ getObjectExpressionKeys() — vue Function Reference

getObjectExpressionKeys() — vue Function Reference

Architecture documentation for the getObjectExpressionKeys() function in compileScript.ts from the vue codebase.

Entity Profile

Dependency Diagram

graph TD
  5df0e9b4_0d3a_2489_eb77_65326f337535["getObjectExpressionKeys()"]
  3dda6db9_d933_350f_4c9e_16f7fc6b1f16["analyzeBindingsFromOptions()"]
  3dda6db9_d933_350f_4c9e_16f7fc6b1f16 -->|calls| 5df0e9b4_0d3a_2489_eb77_65326f337535
  ed2a2fd5_ef3d_843d_ad3d_805dc154d881["getObjectOrArrayExpressionKeys()"]
  ed2a2fd5_ef3d_843d_ad3d_805dc154d881 -->|calls| 5df0e9b4_0d3a_2489_eb77_65326f337535
  style 5df0e9b4_0d3a_2489_eb77_65326f337535 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/compiler-sfc/src/compileScript.ts lines 1751–1766

function getObjectExpressionKeys(node: ObjectExpression): string[] {
  const keys: string[] = []
  for (const prop of node.properties) {
    if (
      (prop.type === 'ObjectProperty' || prop.type === 'ObjectMethod') &&
      !prop.computed
    ) {
      if (prop.key.type === 'Identifier') {
        keys.push(prop.key.name)
      } else if (prop.key.type === 'StringLiteral') {
        keys.push(prop.key.value)
      }
    }
  }
  return keys
}

Domain

Subdomains

Frequently Asked Questions

What does getObjectExpressionKeys() do?
getObjectExpressionKeys() is a function in the vue codebase.
What calls getObjectExpressionKeys()?
getObjectExpressionKeys() is called by 2 function(s): analyzeBindingsFromOptions, getObjectOrArrayExpressionKeys.

Analyze Your Own Codebase

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

Try Supermodel Free