Skip to content

Conversation

SxDx
Copy link
Contributor

@SxDx SxDx commented Dec 30, 2022

As reported in #6253 custom transition classes (e.g. with tailwind) are currently not working when vue is running in compat/migration mode.

This PR just adds a few checks to the Transition component to fix this.
We have been running a vue version with this fix applied in production for months and found no problems.

close: #6253

@SxDx SxDx changed the title Fix for custom transition classes when running in compat mode fix(runtime-core): Fix for custom transition classes when running in compat mode Dec 30, 2022
@SxDx SxDx changed the title fix(runtime-core): Fix for custom transition classes when running in compat mode fix(runtime-core): Support for custom transition classes when running in compat mode Dec 30, 2022
@LinusBorg LinusBorg self-requested a review January 11, 2023 09:25
nextFrame(() => {
removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass)
if (__COMPAT__ && legacyClassEnabled) {
if (__COMPAT__ && legacyClassEnabled && legacyAppearFromClass && legacyEnterFromClass) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@SxDx I think a more straightforward solution could be to initialize these legacy*Class variables as empty strings on line 143-145

@yyx990803 yyx990803 merged commit efe2efd into vuejs:main Feb 1, 2023
zhangzhonghe pushed a commit to zhangzhonghe/core that referenced this pull request Apr 12, 2023
IAmSSH pushed a commit to IAmSSH/core that referenced this pull request May 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Transition not working with custom transition classes in Vue 3 migration build

3 participants