Closed
Description
Version
3.0.5
Reproduction link
https://codesandbox.io/s/priceless-lalande-eh4wx?file=/src/views/Home.vue
Steps to reproduce
- Go to Codesandbox.
- Open console window in Codesandbox.
- First access "Home" page, then move to "About" page.
- You'll see computed value becoming
undefined
. - If you un-comment
console.log(computedObj.value)
right above theonUnmounted
hook. The value becomes visible insideonMountedhook
.
What is expected?
Not sure. Is this expected?
What is actually happening?
Not sure. I think it would be OK for computed
or any other reactive value to be undefined
inside onUnmounted
, but I think it would be better to have consistent behavior.