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

Function shallowRef

packages/reactivity/src/ref.ts:100–102  ·  view source on GitHub ↗
(value?: unknown)

Source from the content-addressed store, hash-verified

98export function shallowRef<T = any>(): ShallowRef<T | undefined>
99/*@__NO_SIDE_EFFECTS__*/
100export function shallowRef(value?: unknown) {
101 return createRef(value, true)
102}
103
104function createRef(rawValue: unknown, shallow: boolean) {
105 if (isRef(rawValue)) {

Callers 14

ref.spec.tsFile · 0.90
computed.spec.tsFile · 0.90
reactive.spec.tsFile · 0.90
readonly.spec.tsFile · 0.90
useTemplateRefFunction · 0.90
fooClass · 0.90
apiWatch.spec.tsFile · 0.90
Suspense.spec.tsFile · 0.85
setupFunction · 0.85
KeepAlive.spec.tsFile · 0.85
Transition.spec.tsFile · 0.85

Calls 1

createRefFunction · 0.85

Tested by 1

setupFunction · 0.68