Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(compiler-core): should not remove slot node with v-else #11150

Merged
merged 3 commits into from
Jun 22, 2024

Conversation

KermanX
Copy link
Contributor

@KermanX KermanX commented Jun 16, 2024

Previously, slot nodes with v-else or v-else-if directives were wrongly removed by the compiler. This caused issues like vuejs/language-tools#3466 and vuejs/language-tools#4443.

Previously, the following source code:

<Comp>
  <template v-if="a" #foo />
  <template v-else #foo />
</Comp>
Parse mode Compile mode
image image

Now, the compile mode's behavior is the same as the parse mode.

@yyx990803 yyx990803 merged commit e102670 into vuejs:main Jun 22, 2024
11 checks passed
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.

2 participants