21

For the last week or so, every .vue files I work with has no syntax highlighting. I usually have the extension Vetur to help with syntax highlighting and other tweaks to .vue files.

Things I've tried so far:

  • uninstall/reinstall Vetur
  • change file associations in VS Code
  • make sure .vue files have no errors

][1]

3
  • 2
    This totally worked! I didn't know you could force VScode to reinstall extensions. This apparently works when doing a manual uninstall/reinstall of the extension didn't work. Run command: Developer: Reinstall Extension for Vetur. Commented Aug 3, 2020 at 14:20
  • I didn't have the Vetur enabled... Commented Nov 7, 2020 at 8:59
  • 1
    These (and many others) github links no longer work Commented Jan 17, 2021 at 12:35

7 Answers 7

25

You can install 'Vue 3 Support - All In One' from extensions in vs code. Then the issue with syntax highlighting will fix.

Sign up to request clarification or add additional context in comments.

2 Comments

worked like a charm :)
you're a friend
6
  1. Disable Volar/Vetur extension
  2. Install and enable Vue 3 Support Extension
  3. Reload VSCode

Comments

2

You can install the "Vue-official" extension from VS Code extensions store, and it will solve all your problems related to syntax highlighting.

Comments

0

As i see for lang="pug" there is no needs to use other extension as like below:

https://vuejs.github.io/vetur/highlighting.html#custom-block

So I think the problem may be on your project file, please check new vue project to be sure that the problem is not from your files and config of the project !

Comments

0

According to Vetur's "No Syntax Highlighting & No Language Features working" FAQ, what you can do to resolve the issue is:

try disabling all other Vue related extensions.

or

Comments

0

I faced same today and solved it by installing "vue-official" extension from visual studio code extensions menu.

Comments

-3

As Sebastian Brosch said in a reply

This worked for me: https://github.com/vuejs/vetur/blob/master/docs/FAQ.md#no-syntax-highlighting--no-language-features-working

TLDR: Run command reinstall command in vscode and select vetur extension

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.