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

Function setup

packages/runtime-dom/__tests__/directives/vShow.spec.ts:185–198  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

183 const display = ref(false)
184 const component = defineComponent({
185 setup() {
186 const innerValue = ref(false)
187 watch(display, val => {
188 innerValue.value = val
189 })
190 return () => {
191 return h(Transition, () =>
192 withVShow(
193 h('div', { style: style.value }, innerValue.value),
194 display.value,
195 ),
196 )
197 }
198 },
199 })
200 render(h(component), root)
201

Callers

nothing calls this directly

Calls 4

refFunction · 0.90
watchFunction · 0.90
hFunction · 0.90
withVShowFunction · 0.85

Tested by

no test coverage detected