Skip to content

Wrap unintended template syntax with v-pre #799

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

Merged
merged 1 commit into from
Jan 10, 2021

Conversation

skirtles-code
Copy link
Contributor

Description of Problem

I made a suggestion in #763 that has introduced a problem. The sequence:

`{{ item }}`

was supposed to be rendered literally. However, VuePress allows for Vue template syntax within the markdown and only code blocks are exempt. Inline code, surrounded by single backticks, is still be treated as a template.

Proposed Solution

I've wrapped the code in a <span v-pre>.

Another alternative would have been to write it as:

`{{ '\u007b\u007b item \u007d\u007d' }}`

That avoids the extra element but on balance I felt using v-pre would be easier to understand.

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