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

Function hasInjectionContext

packages/runtime-core/src/apiInject.ts:92–94  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

90 * user. One example is `useRoute()` in `vue-router`.
91 */
92export function hasInjectionContext(): boolean {
93 return !!(getCurrentInstance() || currentApp)
94}

Callers 2

apiInject.spec.tsFile · 0.85
setupFunction · 0.85

Calls 1

getCurrentInstanceFunction · 0.90

Tested by 1

setupFunction · 0.68