Color different variables differently in VS Code

戏子无情 提交于 2021-02-11 12:31:15

问题


In Visual Studio Code, is it possible to have different local variables be colored differently? Here's an example from a Medium article of what this looks like:

And one from PyCharm:

This is usually called "semantic highlighting" or "semantic coloring", although VS Code uses that to mean syntax highlighting that more intelligently detects whether a word is a regular variable, function, etc. and color that accordingly.

My question here is basically the same as this 2015 GitHub issue that was wrongly closed as a duplicate of an unrelated issue.

I'd be interested in settings or extensions that work for any languages, though particularly Python or JavaScript/TypeScript.

来源:https://stackoverflow.com/questions/61473510/color-different-variables-differently-in-vs-code

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!