Skip to content

Instantly share code, notes, and snippets.

@HenestrosaDev
Last active June 11, 2022 12:25
Show Gist options
  • Save HenestrosaDev/d535a634d1932bbf1ba0471a1c80251c to your computer and use it in GitHub Desktop.
Save HenestrosaDev/d535a634d1932bbf1ba0471a1c80251c to your computer and use it in GitHub Desktop.
Visual Studio Code Shortcuts.md

VISUAL STUDIO CODE SHORTCUTS

Note

There are some shortcuts that are not exclusive to Visual Studio Code. I decided to add them because they are a positive addition to the list. They are marked with an asterisk

  • *: Non-exclusive VS Code shortcut.
  • #: Needs to be configured by the user using the Keyboard Shortcuts option.

Lines

COMMANDS WINDOWS MAC
Show commands list Ctrl + Shift + P + Shift + P
Open settings Ctrl + , + ,
Delete line Ctrl + Shift + K + Shift + K
Copy line Ctrl + C (without selecting anything) + / (without selecting anything)
Cut line Ctrl + X (without selecting anything) + X/kbd> (without selecting anything)
Comment line/block Ctrl + K, release K and then press C + K, release K and then press C
Move line Alt + / + /
Clone line Alt + Shift + / + Shift + /
New line without having to go to the end of the previous line * Ctrl + Enter + Enter

Cursors

COMMANDS WINDOWS MAC
Multiple cursors Ctrl + Alt + / + + /
Exit multiple cursors mode Esc Esc
Create individual multiple cursors Alt Left mouse click

Quick edition

COMMANDS WINDOWS MAC
Delete word * Ctrl + Backspace + Backspace
Wrap individual lines with abbreviation Ctrl + Shift + P and then search for Wrap individual lines with abbreviation + Shift + P and then search for Wrap individual lines with abbreviation

Navigation

COMMANDS WINDOWS MAC
Go to the next occurence of word Ctrl + D + D
Go to specific line Ctrl + G Ctrl + G
Go to symbol in file Ctrl + Shift + O Ctrl + Shift + O
Search Ctrl + F + O
Advanced search Ctrl + Shift + F + Shift + F

Capitalization

COMMANDS WINDOWS MAC
Capitalize selection # Ctrl + Shift + U + Shift + U
To lowercase selection # Ctrl + Shift + L Ctrl + Shift + L

Windows

COMMANDS WINDOWS MAC
Close file window Ctrl + W Ctrl + W
Close all file windows Ctrl + K + W Ctrl + K + W
Change file window Ctrl + Tab Ctrl + Tab
Toggle navigation bar Ctrl + B + B

Emmet snippets

DESCRIPTION SHORTCUT EXAMPLE
Create multiple tags at once [TAG]*[NUMBER OF TAGS] li*4
Create multiple nested tags at once [TAG]*[NUMBER OF TAGS] [CSS SELECTOR] [TAG]*[NUMBER OF TAGS] li*4>p*8
Create multiple nested tags with numbered id [TAG]*[NUMBER OF TAGS] [CSS SELECTOR] [TAG]#[ID]*[NUMBER OF TAGS] ul>li#item$*5

All snippets

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment