Home / Function/ proxy() — vue Function Reference

proxy() — vue Function Reference

Architecture documentation for the proxy() function in state.ts from the vue codebase.

Entity Profile

Dependency Diagram

graph TD
  b28f2cc5_e9df_82f7_d7e9_a1e5617cf102["proxy()"]
  d6eecf16_0b33_9978_9ebb_d8829be93c79["initProps()"]
  d6eecf16_0b33_9978_9ebb_d8829be93c79 -->|calls| b28f2cc5_e9df_82f7_d7e9_a1e5617cf102
  a592e65e_63b6_f3cc_cc80_030328fd88d5["initProps()"]
  a592e65e_63b6_f3cc_cc80_030328fd88d5 -->|calls| b28f2cc5_e9df_82f7_d7e9_a1e5617cf102
  d31fad70_4d19_ce2b_d907_4d8be6615062["initData()"]
  d31fad70_4d19_ce2b_d907_4d8be6615062 -->|calls| b28f2cc5_e9df_82f7_d7e9_a1e5617cf102
  style b28f2cc5_e9df_82f7_d7e9_a1e5617cf102 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

src/core/instance/state.ts lines 42–50

export function proxy(target: Object, sourceKey: string, key: string) {
  sharedPropertyDefinition.get = function proxyGetter() {
    return this[sourceKey][key]
  }
  sharedPropertyDefinition.set = function proxySetter(val) {
    this[sourceKey][key] = val
  }
  Object.defineProperty(target, key, sharedPropertyDefinition)
}

Domain

Subdomains

Frequently Asked Questions

What does proxy() do?
proxy() is a function in the vue codebase.
What calls proxy()?
proxy() is called by 3 function(s): initData, initProps, initProps.

Analyze Your Own Codebase

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

Try Supermodel Free