Sublime Text 3 hot keys

Learn how to use Sublime Text 3's hotkeys & maximize your coding efficiency with an example of how to quickly navigate to a line of code.

Sublime Text 3 Hot Keys

Sublime Text is a powerful text editor that makes coding and writing easier. It comes with a variety of shortcuts that let you quickly access and manipulate text with ease. Here are some of the most useful Sublime Text 3 hot keys.

Navigation

Ctrl + P: Quickly open files and folders with the Go To Anything feature. Type in the name of the file or folder you want to open and Sublime Text will bring you there. You can also navigate to a specific line in the file by typing in the line number.

Selecting

Ctrl + D: Select the current word or line. This can be used to quickly select a word or line for editing or deletion. Pressing Ctrl + D multiple times will select multiple words or lines in succession.

Editing

Ctrl + J: Join the current line with the next one. This is useful for editing and reformatting text. It can also be used to quickly delete empty lines.

Formatting

Ctrl + /: Toggle comment on the current line or selection. This is a great way to quickly comment out code or add a comment to explain what a line of code is doing.

Search & Replace

Ctrl + F: Open the Find panel. This is a great way to quickly search and replace words or phrases in the current file. You can also use the Search & Replace feature to replace words or phrases in multiple files.

Code Folding

Ctrl + K + 1, 2, or 3: Fold and unfold code blocks. This is a great way to quickly collapse code blocks for easier navigation and readability.

Code Autocompletion

Ctrl + Space: Autocomplete code. Sublime Text will suggest relevant code snippets as you type. This is a great way to save time and make coding easier.

Multiple Cursors

Ctrl + Alt + Up/Down: Select multiple lines at once. This is a great way to edit multiple lines of code at the same time. You can also use Sublime Text's multiple selection feature to quickly add or delete code.

Syntax Highlighting

Ctrl + K + B: Show the syntax highlighting. This is a great way to quickly identify syntax errors in your code. You can also use it to quickly switch between different programming languages.

JavaScript

// JavaScript code example
let x = 10;
let y = 15;
let z = x + y;
console.log(z); // prints 25

Answers (0)