fix(reactivity): avoid cross-component dependency leaks in setup()
This commit is contained in:
@@ -9,7 +9,7 @@ import { ComponentPublicInstance } from './componentProxy'
|
||||
import { callWithAsyncErrorHandling, ErrorTypeStrings } from './errorHandling'
|
||||
import { warn } from './warning'
|
||||
import { capitalize } from '@vue/shared'
|
||||
import { pauseTracking, resumeTracking, DebuggerEvent } from '@vue/reactivity'
|
||||
import { pauseTracking, resetTracking, DebuggerEvent } from '@vue/reactivity'
|
||||
|
||||
export { onActivated, onDeactivated } from './components/KeepAlive'
|
||||
|
||||
@@ -39,7 +39,7 @@ export function injectHook(
|
||||
setCurrentInstance(target)
|
||||
const res = callWithAsyncErrorHandling(hook, target, type, args)
|
||||
setCurrentInstance(null)
|
||||
resumeTracking()
|
||||
resetTracking()
|
||||
return res
|
||||
})
|
||||
if (prepend) {
|
||||
|
||||
Reference in New Issue
Block a user