Editor Commands
A list of all the commands available in the Editor.
If you're working in the Editor and press CMD SHIFT P (on Mac) or CTRL SHIFT P (on Windows), the command palette will appear with the Editor commands easily accessible. If you want access to other command palette tools, simply back out the Editor Commands preface. If the editor commands don't show by default, start typing "Editor Commands" until the category appears on screen, and then press Enter to bring them up.
Command | Description | Shortcut |
---|---|---|
Find | Opens up the find widget | CMD/CTRL F |
Replace | Opens up the find / replace widget | CMD/CTRL OPTION F |
Find With Selection | Opens up the find widget with the current selection filled in | |
Find Next | Jumps the next instance of the search query | CMD/CTRL G |
Find Previous | Jumps the previous instance of the search query | CMD/CTRL SHIFT F |
Find Next Selection | Jumps the next instance of the selected text | |
Find Previous Selection | Jumps the previous instance of the selected text |
Command | Description | Shortcut |
---|---|---|
Copy Line Up | Copies the current line to a new line above | SHIFT OPTION ↑ |
Copy Line Down | Copies the current line to a new line below | SHIFT OPTION ↓ |
Duplicate Selection | Inserts a new copy of the current selected text | |
Move Line Up | Moves the current line to the line above | |
Move Line Down | Moves the current line to the line below | |
Sort Lines Ascending | Sorts the currently selected lines alphanumerically, ascending | |
Sort Lines Descending | Sorts the currently selected lines alphanumerically, descending | |
Trim Trailing Whitespace | Removes whitespace from the end of the selection | |
Delete Line | Deletes the current line | CMD/CTRL SHIFT K |
Indent Line | Adds a tab at the beginning of the line | CMD/CTRL ] |
Outdent Line | Removes a tab at the beginning of the line | CMD/CTRL [ |
Insert Line Above | Adds a blank line above the current line without moving the cursor | CMD/CTRL Enter |
Insert Line Below | Adds a blank line below the current line without moving the cursor | CMD/CTRL SHIFT Enter |
Delete All Left | Deletes all text to the left of the cursor on the current line | CMD/CTRL Backspace |
Delete All Right | Deletes all text to the right of the cursor on the current line | CTRL K |
Delete Word | Deletes the current word | |
Join Lines | Combines the selected lines to be on a single line | CTRL J |
Transform to Uppercase | Converts the selected text to be uppercase | |
Transform to Lowercase | Converts the selected text to be lowercase | |
Transform to Title Case | Converts the selected text to be title case | |
Transform to Snake Case | Converts the selected text to be snake case | |
Format Document | Formats the entire document in the editor | SHIFT OPTION F |
Command | Description | Shortcut |
---|---|---|
Rename | When your cursor is inside an HTML element tag name, this allows you to rename the open and closing tag at the same time | |
Expand Selection | Expand the current selection to the next selectable range | |
Shrink Selection | Shrinks the current selection to the previous selectable range | |
Add Selection To Next Find Match | Inserts a cursor and selects the next instance of the search query or selected text | CMD/CTRL D |
Add Selection To Previous Find Match | Inserts a cursor and selects the previous instance of the search query or selected text | |
Move Last Selection To Next Find Match | Selects the next instance of the search query or selected text | |
Move Last Selection To Previous Find Match | Selects the previous instance of the search query or selected text | |
Select All Occurrences of Find Match | Selects all matches of the search query or selected text | |
Select to Bracket | Expands the current selection to the next set of brackets |
Command | Description | Shortcut |
---|---|---|
Add Cursor Above | Inserts a cursor on the line above | CMD/CTRL OPTION ↑ |
Add Cursor Below | Inserts a cursor on the line below | CMD/CTRL OPTION ↓ |
Add Cursors To Bottom | Inserts a cursor on every line until the bottom | |
Add Cursors To Top | Inserts a cursor on every line until the top | |
Cursor Undo | Removes the latest cursor inserted | |
Cursor Redo | Re-inserts the latest cursor removed |
Command | Description | Shortcut |
---|---|---|
Fold | Folds the innermost uncollapsed region at the cursor | CMD/CTRL OPTION [ |
Unfold | Unfolds the collapsed region at the cursor | CMD/CTRL OPTION ] |
Fold Recursively | Folds the innermost uncollapsed region at the cursor and all regions inside that region | |
Unfold Recursively | Unfolds the region at the cursor and all regions inside that region | |
Fold All | Folds all regions in the editor | |
Unfold All | Unfolds all regions in the editor | |
Fold All Block Comments | Folds all block level comments in the editor | |
Fold All Regions Except Selected | Folds all regions, except the region at the current cursor position | |
Unfold All Regions Except Selected | Unfolds all regions, except the region at the current cursor position | |
Toggle Fold | Folds or unfolds the region at the cursor | |
Fold Level X | Folds all regions of level X (1-7), except the region at the current cursor position |
Command | Description | Shortcut |
---|---|---|
Open Link | When your cursor is inside of a URL this command will open the link in a new tab | |
Toggle Tab Key Moves Focus | Toggles whether when Tab is pressed, a tab character is inserted or the focus moves to from the editor to the next item in the app | |
Go to Bracket | Jumps to the next closing tag or bracket | |
Copy With Syntax Highlighting | Copies the selected text to your clipboard with syntax highlighting | |
Toggle Line Comment | Toggles a single line comment | CMD/CTRL / |
Toggle Block Comment | Toggles a multi-line comment | SHIFT OPTION A |
Show Editor Context Menu | Shows the context menu, the same menu displayed on right click | |
Go to Next Problem | Jumps to the next problem highlighted in your code | |
Go to Previous Problem | Jumps to the previous problem highlighted in your code | |
Quick Fix... | Fixes the currently focused problem if an automated solution is available | |
Go to Line/Column... | Jumps to the specified line and column | |
Trigger Suggest | Shows suggestions for the current cursor position | |
Show Hover | Shows the hover widget for the current cursor position |