Closed stoewer closed 8 years ago
Linguist only selects the grammar to use for highlighting. For JavaScript, GitHub uses atom/language-javascript. You should open an issue there if there isn't already one.
@pchaigno This actually seems to be an issue with the HTML syntax.
Seems Linguist is using the TextMate grammar for highlighting instead of Atom's. Interestingly enough, if Atom's grammar is used for highlighting, it works fine.
I think we should switch...
@Alhadis - Ooh, right! @stoewer - textmate/html.tmbundle it is!
I think we should switch...
If they're other issues, I agree. But otherwise, we'd probably better open a pull request ;) That said, I don't think there's a single grammar free of any issue. It's just that difficult to parse context-free grammars with regular expressions :stuck_out_tongue_winking_eye:
That said, I don't think there's a single grammar free of any issue.
Nope, of course not. However, Atom's grammars are updated frequently, and would arguably be a better fit for fast-moving technologies like CSS and HTML. Conversely, TextMate's grammar repos aren't updated all that frequently, and don't receive as much input from users as Atom's grammars do.
@stoewer - textmate/html.tmbundle it is!
Thank's, I'll report it there.
type="text/babel"
should now work in *.vue files as per my pull request here
Closing as this needs to be fixed upstream.
If an html
<script>
tag has the attributetype="text/ecmascript-6"
the content is not highlighted as javascript:However, it does work with
type="text/javascript"
:Some editors and IDEs (e.g. Jetbrains products) require this attribute to be present in order to treat the content of
<script>
tags appropriately. This issue arises frequently when one is using Vue.js with *.vue files like this.The highlighting is also not working if a
<script>
tag hastype="text/babel"
, which is also commonly used to indicate es6 content in a<script>
tag.