VSCode shortcut keys
Visual Studio Code is a code editor made by Microsoft for Windows, Linux, and macOS. VS Code, by far, is the most popular code editor. In the Stack Overflow 2019 Developer Survey, it was ranked highest on the most popular code editor where more than 50% of 87,317 people stated that they are the user of VS Code. Today, I am going to show you how you can increase your productivity by following these commands of VS Code.
1) code .
Type this command in Git Bash or Command Prompt and VSCode will directly open on your PC.
2) Ctrl + Shift + P
A command palette is a functionality that provides access to many commands and the aforementioned key is used to access that functionality i.e. Command Palette. For example: changing theme
3) Ctrl + P
This is one of my favorite shortcut keys. I use this key to find desired files inside a project with huge number of files inside it.
4) Ctrl + Shift + N
This command instantly opens a new instance of VSCode.
5) Alt + up arrow / down arrow
Moves line up or down.
6) Shift + Alt + up arrow / down arrow
Copies a block of line.
7) Ctrl + /
Comments and uncomments a line of code. Pressing Shift + Alt + A will comment a block of code.
8) Home / End
Home sends the cursor at the beginning of the line whereas End sends at the end.
9) Alt + Z
Toggle a word wrap.
10) Search & Replace
Ctrl + F will find your desired word in the code. Besides, helps in replacing the word or words. For example: Let us assume we have 10 words of hello
and you want to replace all those with hello world
. Here is an easy method.
Multi-cursor
11) Alt + click
This command is handy when you have to insert multiple cursors.
12) Ctrl + Alt + Up/Down
Inserts cursor above and below.
Integrated Terminal
13) Ctrl + backtick
This shortcut toggles integrated terminal. You can press Ctrl + Shift + backtick
to start a new terminal or simply click on +
icon as shown on the git.
So, these were some shortcut keys that I use often. However, this is not the end of keys. There are plethora of other keys which you can find in the documentation link of Visual Studio Code. Feel free to check the provided link.
Thank you for reading. You can follow me on Twitter here.