It is expected to allow for garbage collector to collect CompMarker object after v-if expression evaluates to false.
What is actually happening?
CompMarker object is found in JS heap. The weird thing is that when v-if outcome is changed to false from other component (click on Remove child from 2), the CompMarker is removed from heap.
Vue version
3.5.13
Link to minimal reproduction
https://play.vuejs.org/#eNq1U02L2zAQ/StCFyewtUnSXlJn2XbJoYV+kC49CYprjxNt9GEk2Rsw/u8dSY2TLO0SCgUfrJnnp/dmnnv6rmnSrgW6pLktDW8cseDa5pYpLhttHOmJgZoMpDZakgShydi617KZ/W6kWTh5ruTtBWJ+gZgfEUyVWlmH7KoCc7/joiIrf9fEmRamAZFnUROqwYMD2YjCAZ4IyePl3Sterxg9I2GU3O14VYG6rCN5XQgL2M9ODPOrwHl2dje9oc6i9ppv00erFY6u93yMlkjIBZgvjePojdElCR3fK4TQTx9Dzfu7OdbLHZT7P9Qf7cHXGP1qwILpUMrYc4XZgovt9bfPcMD3sSl11QpEv9DcgNWi9Roj7H2rKpR9hgtqP4QdcrV9sOuDA2WPprxQjxwCnlHcqJ/l36yf5C7S1+E7pgac4hiY5+EjolBbXIhDHhx4zAlI7nAtFdRcwRoPNu/JBLz+uEFGp0vSaV6R4XYS81OKwtoQwk+F2YOJmqyWsClUpeX3QrSApIw+7Lgl+ISoljFHqPIUUxkJVkTB0xljuOilmFa8Cy+E9P2RZEBeX8l/ts5pRe5Kwcs9GvYeJ0m0k0zR/Aak7iAKitpmeRa/ivRZ5H8e0PFP+0+jvc7xv/ibX+XvRwfGxxHtLdI36WxBh18WKJsI
Steps to reproduce
Remove child from 1
CompMarker
in Memory snapshotWhat is expected?
It is expected to allow for garbage collector to collect
CompMarker
object afterv-if
expression evaluates tofalse
.What is actually happening?
CompMarker
object is found in JS heap. The weird thing is that whenv-if
outcome is changed to false from other component (click onRemove child from 2
), theCompMarker
is removed from heap.System Info
Any additional comments?
No response