MCPcopy
hub / github.com/vuejs/core / def

Function def

packages/shared/src/general.ts:152–164  ·  view source on GitHub ↗
(
  obj: object,
  key: string | symbol,
  value: any,
  writable = false,
)

Source from the content-addressed store, hash-verified

150}
151
152export const def = (
153 obj: object,
154 key: string | symbol,
155 value: any,
156 writable = false,
157): void => {
158 Object.defineProperty(obj, key, {
159 configurable: true,
160 enumerable: false,
161 writable,
162 value,
163 })
164}
165
166/**
167 * "123-foo" will be parsed to 123

Callers 4

markRawFunction · 0.90
initSlotsFunction · 0.90
mountElementFunction · 0.90
hydrateNodeFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected