Multi-Cursor Editing & Refactoring
Multi-cursor editing lets you make the same change in multiple places simultaneously. Combined with VS Code's refactoring tools, it is one of the most time-saving features in the editor.
1Adding Cursors
Alt+Click Add a cursor at click position Ctrl+Alt+Up/Down Add cursor above / below Ctrl+D Select next occurrence of word Ctrl+Shift+L Select ALL occurrences Ctrl+U Undo last cursor operation
2Column (Box) Selection
Hold Shift+Alt and drag to select a rectangular block of text. This is perfect for editing columns of data — you can type and all selected columns update at once. You can also use Shift+Alt+Down to extend the selection row by row.
3Rename Symbol
Press F2 on any variable, function or class name to rename it across your entire project — including all imported files. VS Code uses the language server to find every reference safely, unlike a raw text find-replace.
4Extract to Function / Variable
Select any expression, right-click → Refactor → Extract to Constant or Extract to Function. VS Code creates the new symbol and replaces the selection with a reference to it automatically.
5Move to New File
Right-click a class or function → Refactor → Move to New File. VS Code creates a new file, moves the symbol, and updates all imports across the project. A huge time-saver when reorganising a codebase.