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 '@' inside single quotes breaks javascript syntax highlighting #190

Open
mdelem opened this issue Sep 9, 2013 · 1 comment
Open

Comments

@mdelem
Copy link

mdelem commented Sep 9, 2013

For example, the following snippet will not be colored:

$('.rating_typeahead').typeahead({
remote: '@routes.SurveyController.getAspects(userId, "%QUERY")'
});

@skyluc
Copy link
Member

skyluc commented Sep 10, 2013

Standalone test case:

@()

<html>
  <head>
    <script type="text/javascript">
      var a= "test"
    </script>
    <script type="text/javascript">
      var b = "@test"
    </script>
  </head>
</html>

Syntax highlighting works fine in the first javascript block, and not at all in the second block. Removing the @ sign fix the problem in the second block.

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

2 participants