VS Code Autocorrect

拥有回忆 提交于 2019-12-02 09:07:58

问题


I'm looking for a way to automatically replace my commonly misspelt words in VS Code.

Is there something out there / how would I create something where I can add a particular string to find, string to replace with and a syntax/filetypes for the autocorrect to be active in?

Example:

backgorund | background | css/scss/less

To clarify, I want it to be automatically corrected, no key inputs.

Many thanks!


回答1:


There is an Auto Correct extension for VS Code.

Its configuration is pretty straightforward. In your case just add the following to your settings.json

"auto-correct.dictionary": [
{
  "languages": ["javascript","css","html"],
  "words": {
    "backgorund": "background"
  }
}]

And "backgorund" will be automatically corrected without specific key presses.



来源:https://stackoverflow.com/questions/51397895/vs-code-autocorrect

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