hedefalk / atom-vue

Vue component file syntax for Atom

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

JS highlight syntax problem in tag <script>....

Recly opened this issue · comments

Hello! Faced such a problem, with your plugin for Vue.js, JavaScript syntax is incorrectly highlighted in the <script> tag. If I change the language to HTML, then everything is highlighted fine. How can this problem be solved?

tagVue
htmlVue

I know this is an older issue, but here's essentially what happens.

This package language-vue does very little to actually highlight any JavaScript. Essentially, this package recognizes that you've added JavaScript and instead says, Atom/Pulsar find the package that can highlight source.js and use that here. Then whatever package is selected it used.

So it seems whatever package is being selected is not the one you prefer and is providing a different code highlighting than you prefer. What's strange is I'd assume that language-html which is bundled into Atom/Pulsar would be doing the same exact thing, so I'm not sure why they have the different behavior. What I'd recommend is you take a look through your community package's to determine if there's additional packages that provide syntax highlighting for JavaScript and disable them one by one, until you see this issue is resolved. Once you do, then you'll be able to determine which package is providing the unwanted highlighting behavior.