@manhng

Welcome to my blog!

Visual Studio Code - Keyboard Shortcuts

December 22, 2017 01:03

A complete, yet simple, starter for Angular v2+ using webpack

https://github.com/preboot/angular-webpack

node -v
npm -v

npm i -g npm

git clone https://github.com/preboot/angular-webpack.git QuickStart

cd QuickStart

npm install

npm start

http://localhost:8080

npm run build

Navigate to the directory that you want to open and type code . to launch VS Code.
code .
code-insiders .

Learn how to install Git, Node.js, TypeScript and tools like Yeoman.

Keyboard Shortcuts in Windows
https://code.visualstudio.com/shortcuts/keyboard-shortcuts-windows.pdf

Alternatively, you can use Alt+Left and Alt+Right to navigate between files and edit locations.

Tip: You can move the Side Bar to the right hand side (View > Move Side Bar Right) or toggle its visibility (Ctrl+B).

Tip: Type Ctrl+P (Quick Open) to quickly search and open a file by its name.

The Command Palette provides access to many commands. You can execute editor commands, open files, search for symbols, and see a quick outline of a file, all using the same interactive window. Here are a few tips:

Ctrl+P will let you navigate to any file or symbol by typing its name
Ctrl+Shift+Tab will cycle you through the last set of files opened
Ctrl+Shift+P will bring you directly to the editor commands
Ctrl+Shift+O will let you navigate to a specific symbol in a file
Ctrl+G will let you navigate to a specific line in a file

Keyboard Shortcuts
Here are some handy keyboard shortcuts to quickly navigate between editors and editor groups.

Ctrl+PageDown go to the right editor.
Ctrl+PageUp go to the left editor.
Ctrl+Tab open the next editor in the editor group MRU list.
Ctrl+Shift+Tab open the previous editor in the editor group MRU list.
Ctrl+1 go to the leftmost editor group.
Ctrl+2 go to the center editor group.
Ctrl+3 go to the rightmost editor group.
Ctrl+K Ctrl+Left go to the previous editor group.
Ctrl+K Ctrl+Right go to the next editor group.
Ctrl+F4 close the active editor.
Ctrl+K W close all editors in the editor group.
Ctrl+K Ctrl+W close all editors.

Tip: You can open any file by its name when you type Ctrl+P (Quick Open).

Ctrl+`: Open terminal window
Ctrl+Shift+`: Add new terminal window

Tip: You can jump to the definition with Ctrl+Click or open the definition to the side with Ctrl+Alt+Click.

Tip: You can jump to the matching bracket with Ctrl+Shift+\

Languages can also support jumping to the implementation of a symbol by pressing Ctrl+F12.

You can click on the summary or press Ctrl+Shift+M to display the PROBLEMS panel with a list of all current errors.

Tip: To loop through errors or warnings in the current file, you can press F8 or Shift+F8 which will show an inline zone detailing the problem and possible code actions (if available)

Tip: The suggestions widget supports CamelCase filtering meaning you can type the letters which are upper cased in a method name to limit the suggestions. For example, "cra" will quickly bring up "createApplication".

As provided by the language service, you can see quick info for each method by either pressing Ctrl+Space or clicking the info icon.

Tip: If a workspace contains a "launch.json" the global launch configuration is ignored.

Tip: We support regular expression searching in the search box, too.

You can configure advanced search options with Ctrl+Shift+J. This will show additional fields to configure the search.

Tip: You can quickly reuse a previous search term by using Alt+Down and Alt+Up to navigate through your search term history.

Format Document (Shift+Alt+F) - Format the entire active file.
Format Selection (Ctrl+K Ctrl+F) - Format the selected text.

Use Shift + Click on the folding icon to fold or unfold the region and all regions inside.

You can also use the following actions:

Fold (Ctrl+Shift+[) folds the innermost un-collapsed region at the cursor.
Unfold (Ctrl+Shift+]) unfolds the collapsed region at the cursor.
Fold Recursively (Ctrl+K Ctrl+[) folds the innermost un-collapsed region at the cursor and all regions inside that region.
Unfold Recursively (Ctrl+K Ctrl+]) unfolds the region at the cursor and all regions inside that region.
Fold All (Ctrl+K Ctrl+0) folds all regions in the editor.
Unfold All (Ctrl+K Ctrl+J) unfolds all regions in the editor.
Fold Level X (Ctrl+K Ctrl+2 for level 2) folds all regions of level X, except the region at the current cursor position.
Fold All Block Comments (Ctrl+K Ctrl+/) folds all regions that start with a block comment token.

Fold Marker Regions (Ctrl+K Ctrl+8) folds all marker regions.
Unfold Marker Regions (Ctrl+K Ctrl+9) unfolds all marker regions.

Command Palette (Ctrl+Shift+P)
Ctrl+F5: Start Without Debugging action is triggered with Ctrl+F5
F5: Start your debug session with F5.
Continue / Pause F5
Step Over F10
Step Into F11
Step Out Shift+F11
Restart Ctrl+Shift+F5
Stop Shift+F5

Categories

Recent posts