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

Using < or > in comments causes them to be detected as code #1

Open
jensbodal opened this issue Nov 1, 2014 · 1 comment
Open

Using < or > in comments causes them to be detected as code #1

jensbodal opened this issue Nov 1, 2014 · 1 comment

Comments

@jensbodal
Copy link

I was trying to display my .vimrc file on my site, the exact text is:

"Sets shift '<' '>' column width
set shiftwidth=4

Once the > or < character is detected, the rest of the comment is displayed as code. I'm not familiar with css and prism markup to fix, any tips? Thanks.

@jensbodal
Copy link
Author

I fixed the issue by changing the order of comment and string:

Prism.languages.vim = {
        'comment': /("+[^"\r\n]*|^".*)(\r?\n|$)/g,
        'string': /("|')(\\?.)*?\1/g,
        'keyword': 

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

No branches or pull requests

1 participant