Subscribe on changes!

html comment inside <Transition> cannot be animated

avatar
Jan 5th 2023

Vue version

3

Link to minimal reproduction

https://sfc.vuejs.org/#eNp9UstOwzAQ/JXFF0CqkybHkhYQn8A1EkqTDXWJ7cjetIcq/846CX0Ct/XszOzLB/HattGuQ7EQGaFum4JwlRuAjFxhvCJlDZhC4zIXdVGhpGLdYC5A2ypgtiOpTC4GDaverG6tQUMJ7KSqmcGCD1XBcgkJy+IbYspEbDxes+dHdhafehmAAVx3RNzbS9mo8utMCVPwDHNYhJpTxfe9onITsn40HQ04y/6nyfnpS6daAo/UtYwobtQRHMBhDT3Uzmq455XdH1NnQ4/ZKA5QEhb7Cyu9YKUTK4xVWuPpZ4BlKPiQPD6FDseeuBsxE6Of1EUbbb01fLrDIJ8SPhcLGJCAsXl452JD1PpFHPu6DBW3PrLuM+Yocp0hpTFCr+Xa2b1Hx8a5mJ15xAzu0EmHpkKH7j/PK+qNb7Dtc9PzKMc13f6/TboKWUiymEM+DGV3UoK3GqG0WvMiQcrr802ew1L/9kwnz0tp/w1YaAUJ

Steps to reproduce

  1. Two components inside transition
  2. Component 1 includes html comment in the template root
  3. Switch state to trigger transition - transition breaks with no console warning

What is expected?

An error for multiple root components inside transition elements does not show when html comment is present inside template root. Vue warning should output when html comment is present in root component template:

Component inside <Transition> renders non-element root node that cannot be animated.

What is actually happening?

No condole warning is shown. Transition stops working on state change.

System Info

No response

Any additional comments?

No response