DEV Community

tellitwithcode
tellitwithcode

Posted on

The only best shortcut every beginner developer should remember when using VS Code on macOs

This shortcut could help to discover faster usage of VS Code.

The magic shortcut is

⌘K ⌘S
Enter fullscreen mode Exit fullscreen mode

When you write this shortcut in VS Code on you Mac a new window called Keyboard Shortcuts opens.

Screenshot of Keyboard Shortcuts table in VS Code

You can find a lot of very useful shortcuts that can streamline your everyday workflow with VS Code.

One of the could be

⇧⌘L
Enter fullscreen mode Exit fullscreen mode

This shortcut selects all occurrences of current selection. So for example when you are in a file where you want to replace : with = on all 10 places within the file you can select the first : then hit the shortcut and it will select all of :. Then you can edit it with =. Lovely, isn't it?

Screenshot of Keyboard Shortcuts table in VS Code

In the first column called Command you have the description of the command. You can search within the commands with the search bar above the table. The keyboard shortcut combination is right to the Command column in the Keybinding column.

On the right side within the search bar there are 3 icons:

  1. The first icon enables you to record keys you hit on you keyboard and if the combination is valid shortcut it will search it in the list.

  2. You can change the alphabetical order of the shortcuts

  3. When you write something in the search bar and you want to delete it you can hit the last third icon. It will clean the search bar.

Changing the shortcut according to your preferences

On the left side within each line of the table there is a small pencil which enables you to edit the shortcut.

Showing where to edit the keyboard shortcut in VS Code Keyboard Shortcuts table

You can write your own preferable combination and after hitting enter you can use it. When there is a match between your new combination and any of the combinations within the table it will give you a hint.

Other sources of shortcuts

Of course there are lot of videos and articles about the shortcuts for VS Code and macOs. For those who prefer to have the shortcuts within one PDF there is a one right from VS Code. You can find it here Keyboard shortcuts macOs

What is your favourite shortcut when using VS Code on macOs?
Inspire us all in comments :)

FOLLOW tellitwithcode on Instagram

Photo by Juan Gomez on Unsplash

Top comments (0)