Open
Description
Vue version
3.5.4
Link to minimal reproduction
Steps to reproduce
Click the button
What is expected?
Both should transition in
What is actually happening?
One transitions correctly, the other throws a warning and blinks into existance
System Info
System:
OS: Linux 5.15 Ubuntu 22.04.4 LTS 22.04.4 LTS (Jammy Jellyfish)
CPU: (16) x64 AMD Ryzen 7 PRO 6850HS with Radeon Graphics
Memory: 11.86 GB / 15.28 GB
Container: Yes
Shell: 5.1.16 - /bin/bash
Binaries:
Node: 22.2.0 - ~/.nvm/versions/node/v22.2.0/bin/node
Yarn: 3.2.2 - ~/.nvm/versions/node/v22.2.0/bin/yarn
npm: 10.7.0 - ~/.nvm/versions/node/v22.2.0/bin/npm
pnpm: 7.25.0 - ~/.nvm/versions/node/v22.2.0/bin/pnpm
bun: 1.1.8 - ~/.bun/bin/bun
Browsers:
Chrome: 126.0.6478.55
Any additional comments?
This is a follow up from
My Intention in #5836 was, that a user should be able to do this:
<Transition>
<CustomComp />
</Transition>
<!-- Custom Comp -->
<Teleport>
<div></div>
</Teleport>
However, the fix for #5836 only allows:
<Transition>
<Teleport>
<div></div>
</Teleport>
</Transition>
For me as a user those 2 should feel equivalent.
The way it is now is not really useful. If you are not gonna use a custom component inside transition, you could just easily swap teleport and transition around (which already worked before the fix):
<teleport>
<transition>
<div></div>
</transition>
</teleport>
But the whole point of #5836 was to allow to transition any component that teleports internally.
And since nesting a custom component into a transition works already, teleport should just be transparent in this case
Usecase:
- modals
<transition><Modal /></transition>
- popovers
- ...