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

Function callAsyncHook

packages/runtime-core/src/components/BaseTransition.ts:369–380  ·  view source on GitHub ↗
(
    hook: Hook<(el: any, done: () => void) => void>,
    args: [TransitionElement, () => void],
  )

Source from the content-addressed store, hash-verified

367 }
368
369 const callAsyncHook = (
370 hook: Hook<(el: any, done: () => void) => void>,
371 args: [TransitionElement, () => void],
372 ) => {
373 const done = args[1]
374 callHook(hook, args)
375 if (isArray(hook)) {
376 if (hook.every(hook => hook.length <= 1)) done()
377 } else if (hook.length <= 1) {
378 done()
379 }
380 }
381
382 const hooks: TransitionHooks<TransitionElement> = {
383 mode,

Callers 2

enterFunction · 0.85
leaveFunction · 0.85

Calls 2

everyMethod · 0.80
callHookFunction · 0.70

Tested by

no test coverage detected