MCPcopy
hub / github.com/vuejs/composition-api / proxy

Function proxy

src/utils/utils.ts:17–28  ·  view source on GitHub ↗
(
  target: any,
  key: string,
  { get, set }: { get?: Function; set?: Function }
)

Source from the content-addressed store, hash-verified

15export const noopFn: any = (_: any) => _
16
17export function proxy(
18 target: any,
19 key: string,
20 { get, set }: { get?: Function; set?: Function }
21) {
22 Object.defineProperty(target, key, {
23 enumerable: true,
24 configurable: true,
25 get: get || noopFn,
26 set: set || noopFn,
27 })
28}
29
30export function def(obj: Object, key: string, val: any, enumerable?: boolean) {
31 Object.defineProperty(obj, key, {

Callers 11

injectStylesFunction · 0.90
toVue3ComponentInstanceFunction · 0.90
createSetupContextFunction · 0.90
constructorMethod · 0.90
proxyRefsFunction · 0.90
defineAccessControlFunction · 0.90
shallowReactiveFunction · 0.90
shallowReadonlyFunction · 0.90
asVmPropertyFunction · 0.90
updateVmAttrsFunction · 0.90
provideFunction · 0.90

Calls

no outgoing calls

Tested by 1

injectStylesFunction · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…