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

HTML block comments & single quotes not parsed correctly #6150

Closed
Muffinman opened this issue Jul 18, 2017 · 1 comment · Fixed by #6156
Closed

HTML block comments & single quotes not parsed correctly #6150

Muffinman opened this issue Jul 18, 2017 · 1 comment · Fixed by #6156
Labels

Comments

@Muffinman
Copy link

Muffinman commented Jul 18, 2017

Version

2.4.1

Reproduction link

https://codepen.io/anon/pen/dREmrV

Steps to reproduce

Using the new comments: true property on a vue instance does not understand block comments, and it also errors when single quotes ' are used within inline comments.

This is particularly annoying in Drupal development when debugging templates, since the template debug output is done using block comments and contains single quotes. See codepen example for a typical Drupal comment block output.

What is expected?

Comments should be rendered correctly within the outputted HTML.

What is actually happening?

VueJS fails to render the instance and throws an exception when trying to parse the comments.


I believe this would happen when using Drupal 7 or 8 with development debugging turned on, when using Vue 2.4 .

@Muffinman Muffinman changed the title HTML Block comments not working HTML Block comments not parsed Jul 18, 2017
@Muffinman Muffinman changed the title HTML Block comments not parsed HTML block comments & single quotes not parsed correctly Jul 18, 2017
@LinusBorg LinusBorg added the bug label Jul 18, 2017
@gebilaoxiong
Copy link
Member

Looks only need to do a small changes

in https://github.com/vuejs/vue/blob/dev/src/compiler/codegen/index.js#L445

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants