watchEffect not triggered sometimes when ref mutation happens inside onMounted #3806
Labels
❗ p4-important
Priority 4: this fixes bugs that violate documented behavior, or significantly improves perf.
🐞 bug
Something isn't working
Version
3.1.0-beta.3
Reproduction link
reproduce at SFC Playground
Steps to reproduce
Open the included SFC Playground reproduce link, and open the browser dev tool console to check the log
What the code does:
What is expected?
On the console I am expecting to see
watchEffect
in the Child component to be triggered twice: once immediately, and once when theinitialized
ref is set. Specifically, I am expecting to seeat the end of the console log
What is actually happening?
watchEffect in the Child is NOT triggered when the
initialized
is set insideonMounted
. Console log indicateswatchEffect
is only triggered once:The text was updated successfully, but these errors were encountered: