Can VS Code have a Color Theme for each Language?

Asked

Viewed 388 times

2

My question is this. I would like to have a theme of simpler colors and with less colors to work with CSS, already for HTML I would like to have a theme with more accentuated and marked colors.

For example when opening a file .HTML I want to use the theme Monokai, but if I open a file .CSS in another tab I want the theme Dracula

You could configure VS Code to use a Color Theme for each file extension at the same time in different tabs?


OBS: before they ask me questions about ferramentas comuns entre programadores are within the scope of the ok site /help/on-topic

  • Hard this... I’m going through the Séttings and the Ocs here and nothing...

  • @fernandosavio the most I could get was an extension... and a link to an Issue https://github.com/Microsoft/vscode/issues/20652

1 answer

1

I still don’t consider the perfect option. But I got a extension of the VS Code that does this!

https://marketplace.visualstudio.com/items?itemName=jsaulou.theme-by-language

It works like this, first vc opens a file with the extension you want, or creates a new file and saves with the extension you want, type one .html or .js

So with this file open and its tab active on your screen you give a Ctrl+shit+p and at the type prompt Set theme for current file language as in the image:

inserir a descrição da imagem aqui

Now whenever you click on a tab that has a file with this extension open your theme will change. What I didn’t like is that it changes the theme of VS Code as a whole, but I would like to use the new theme configs only within the Editor Workbench

Here’s how it works: (there’s a little delay in the exchange of themes, but I think this is a matter of hardware...)

inserir a descrição da imagem aqui

I won’t accept my own answer because I think in the future you’ll have a better way to treat it

Browser other questions tagged

You are not signed in. Login or sign up in order to post.