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

Function defineChild

packages/runtime-core/__tests__/apiOptions.spec.ts:379–385  ·  view source on GitHub ↗
(injectOptions: any, injectedKey = 'b')

Source from the content-addressed store, hash-verified

377 })
378
379 const defineChild = (injectOptions: any, injectedKey = 'b') =>
380 ({
381 inject: injectOptions,
382 render() {
383 return this[injectedKey]
384 },
385 }) as any
386
387 const ChildA = defineChild(['a'], 'a')
388 const ChildB = defineChild({ b: 'a' })

Callers 1

apiOptions.spec.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected