3 Tricks on VS Code

I’ve been using the first one since the last update.

The options are very minimal, but really helpful !! let me know how do you feel using them.

Enabling bracket pair colorization

“editor.bracketPairColorization.enabled”: true,


This content originally appeared on DEV Community and was authored by Marcos RJJunior

I've been using the first one since the last update.

The options are very minimal, but really helpful !! let me know how do you feel using them.

Enabling bracket pair colorization

"editor.bracketPairColorization.enabled": true,

bracket pair colorization

Enabling Auto complete your sentence

"editor.suggest.preview": true,

auto complete sentence

Sorting code

{
    "key": "shift+alt+s",
    "command": "editor.action.sortLinesAscending"
}

Running multiple actions using macros

Because this is still not native feature, I'm using the macros extension.

{
    "key": "shift+alt+f",
    "command": "macros.fixDocumentAndSort",
    "when": "editorHasDocumentFormattingProvider && editorTextFocus && !editorReadonly && !inCompositeEditor"
}
"macros": {
    "eslintFixAndFormatDocument": [
        "eslint.executeAutofix",
        "editor.action.formatDocument"
    ],
},

In this binding, vscode is performing two actions

  • formatting the document
  • fixing eslint issues.


This content originally appeared on DEV Community and was authored by Marcos RJJunior


Print Share Comment Cite Upload Translate Updates
APA

Marcos RJJunior | Sciencx (2022-01-02T04:21:48+00:00) 3 Tricks on VS Code. Retrieved from https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/

MLA
" » 3 Tricks on VS Code." Marcos RJJunior | Sciencx - Sunday January 2, 2022, https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/
HARVARD
Marcos RJJunior | Sciencx Sunday January 2, 2022 » 3 Tricks on VS Code., viewed ,<https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/>
VANCOUVER
Marcos RJJunior | Sciencx - » 3 Tricks on VS Code. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/
CHICAGO
" » 3 Tricks on VS Code." Marcos RJJunior | Sciencx - Accessed . https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/
IEEE
" » 3 Tricks on VS Code." Marcos RJJunior | Sciencx [Online]. Available: https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/. [Accessed: ]
rf:citation
» 3 Tricks on VS Code | Marcos RJJunior | Sciencx | https://www.scien.cx/2022/01/02/3-tricks-on-vs-code/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.