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

v-else fails on "prod" build when preceded by an HTML comment #1256

Closed
marcusball opened this issue May 28, 2020 · 0 comments
Closed

v-else fails on "prod" build when preceded by an HTML comment #1256

marcusball opened this issue May 28, 2020 · 0 comments

Comments

@marcusball
Copy link

Version

3.0.0-beta.14

Reproduction link

https://jsbin.com/vazujatufe/1/edit?html,output

Steps to reproduce

Use Vue via the embedded CDN "vue.global.prod.js" file.

Place an HTML comment block (<!-- -->) just before an element using v-else.

What is expected?

An element with a v-else condition should not be rendered when the preceding v-if condition is satisfied. HTML comments should not effect rendering behavior.

What is actually happening?

The element will still be visible even if the preceding v-if condition is satisfied.

If the comment block is removed, the v-else condition will work properly.


This issue is NOT present with the dev "vue.global.js" CDN file, as can be seen if you swap the commented out <script> tags in the minimal reproduction example.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.