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

v3.2.34-beta.1: regression with v-if and comments #5946

Closed
cexbrayat opened this issue May 18, 2022 · 1 comment
Closed

v3.2.34-beta.1: regression with v-if and comments #5946

cexbrayat opened this issue May 18, 2022 · 1 comment

Comments

@cexbrayat
Copy link
Member

Link to minimal reproduction

https://sfc.vuejs.org/#__DEV__eyJBcHAudnVlIjoiPHNjcmlwdCBzZXR1cD5cbmltcG9ydCB7IHJlZiB9IGZyb20gJ3Z1ZSc7XG5cbmNvbnN0IGVycm9yID0gcmVmKGZhbHNlKTtcbjwvc2NyaXB0PlxuXG48dGVtcGxhdGU+XG4gIDwhLS0gY29tbWVudCAtLT5cbiAgPGRpdj5cbiAgICA8ZGl2IHYtaWY9XCJlcnJvclwiPnYtaWY8L2Rpdj5cbiAgICA8YnV0dG9uIEBjbGljaz1cImVycm9yID0gIWVycm9yXCI+Q2xpY2s8L2J1dHRvbj5cbiAgPC9kaXY+XG48L3RlbXBsYXRlPlxuIiwiaW1wb3J0LW1hcC5qc29uIjoie1xuICBcImltcG9ydHNcIjoge1xuICAgIFwidnVlXCI6IFwiaHR0cHM6Ly91bnBrZy5jb20vQHZ1ZS9ydW50aW1lLWRvbUAzLjIuMzQtYmV0YS4xL2Rpc3QvcnVudGltZS1kb20uZXNtLWJyb3dzZXIuanNcIlxuICB9XG59In0=

Steps to reproduce

Consider a simple v-if in a template with a comment

<script setup>
import { ref } from 'vue';

const error = ref(false);
</script>

<template>
  <!-- comment -->
  <div>
    <div v-if="error">v-if</div>
    <button @click="error = !error">Click</button>
  </div>
</template>

What is expected?

The div is shown when clicking on the button in v3.2.33

What is actually happening?

The div is dnot shown in v3.2.34-beta.1, except if the comment is removed.

System Info

System:
    OS: macOS 12.3.1
    CPU: (10) arm64 Apple M1 Max
    Memory: 32.13 GB / 64.00 GB
    Shell: 5.8 - /bin/zsh
  Binaries:
    Node: 16.15.0 - ~/.volta/tools/image/node/16.15.0/bin/node
    Yarn: 1.22.17 - ~/.volta/tools/image/yarn/1.22.17/bin/yarn
    npm: 8.10.0 - ~/.volta/tools/image/npm/8.10.0/bin/npm
  Browsers:
    Chrome: 101.0.4951.64
    Firefox: 100.0
    Safari: 15.4
  npmPackages:
    vue: 3.2.34-beta.1 => 3.2.34-beta.1

Any additional comments?

No response

@edison1105
Copy link
Member

caused by 2bab639

@github-actions github-actions bot locked and limited conversation to collaborators Sep 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants