11 Useful VSCode Shortcuts: For More Comfortable Development
Tags: vscode, programming, devops
Published: 2024-04-16 14:00:00

## Introduction

Hello, my name is Yohei, and I am an engineer from _WESEEK, Inc._ in Japan.

Usually, when you have a word you want to copy, you select a range of words by dragging from one end to the other, right-clicking to open options, clicking copy, and so on. Honestly, it is time-consuming when engineers use VSCode every day.

Thus, this article will talk about 11 useful shortcuts in VSCode, with the goal of increasing the number of users who know how to make things easier.

Let us start now! Here is a list of the shortcuts and we will explain them one by one later.

---

### 1. Open/Close Sidebar
You can literally open and close the sidebar. This is recommended when you want to keep the screen width of the file you are editing.

![Open/Close Sidebar Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4u0rhq27imqqvh9g7wwe.png)

![Open/Close Sidebar](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3a3sxj3cya3coppyjc2g.gif)

### 2. Open Folder List
You can open the list of folders and files in the sidebar. It can be executed even when the sidebar is closed or when a folder list other than the folder list is open in the sidebar.

![Open Folder List Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kw1g5ygvsr1uivfzrzfs.png)

![Open Folder List](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kdleoo4gz8ry12nlii5z.gif)

### 3. Open Search
You can open a SEARCH in the VSCode sidebar. When executed with a specific string range selected, the search opens and simultaneously searches for files containing the selected keywords. This is recommended when you want to search which files a certain function or variable is used in.

![Open Search Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/mw3zot3rd1gvmi2iw3xe.png)

![Open Search](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xrh3w5xcude5kbisj4iu.gif)

### 4. Open File Search
Enter a file name and it will suggest a list of files with file names that match or are close to the keyword.

If you know the file name, it is recommended to use this way instead of the sidebar.

![Open File Search Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xzeuja311e05czxryx8q.png)

![Open File Search](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/slaynvvoudq5cbdikq7z.gif)

### 5. Open/Close Terminal
You can open and close the terminal. Entering a shortcut from a closed terminal opens the terminal and switches the focus of the input to the terminal. Entering a shortcut from the open state will close the terminal.

This is recommended when you want to look at a wide range of edited files or when you want to open the terminal immediately.

![Open/Close Terminal Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qfi5cjh0tdrdsfgjjau5.png)

![Open/Close Terminal](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k5czmfr058z56nnqhjcl.gif)

### 6. Split Terminal
Each independent terminal can be split on the same tab.

This is recommended for listing out all the information rather than opening a new tab.

![Split Terminal Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nvaiw544y2msdknm3p65.png)

![Split Terminal](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hurlnzpvzyhdzct8xvak.gif)

### 7. Select Word Range
Words that exist at the cursor position are automatically range-selected.
When executed consecutively, the same word found next is selected in turn by the multi-cursor.

![Select Word Range Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/2kublbvqoxm0tffso5pw.png)

![Select Word Range](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zayiaznuzkpf5p8uve2y.gif)

### 8. Copy Line (when not selected)
You can copy the entire line where the cursor is located. If a range is selected, only that range will be copied.
Simply click the cursor anywhere on the line you wish to copy. Then you can graduate from the pain of careful range selection with the mouse.

![Copy Line Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ev2orj8bf7z02d1lkvgu.png)

![Copy Line](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/aa1m8ffidkd8r465bdo5.gif)

### 9. Erase Line (when not selected)
You can delete the entire line where the cursor is located. If a range is selected, only that range will be targeted.
Simply click the cursor anywhere on the line you wish to delete.

![Erase Line Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dch858eesbbk9uig083e.png)

![Erase Line](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/en346ompv26wrogp4ymn.gif)

### 10. Close File
You can close the file that is currently in focus. Then there is no need to press the Close button.
It is recommended to learn this function with the "Re-open a Closed File" shortcut that will be introduced next.

![Close File Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/dzcw8ltiibip2a9cjmpt.png)

![Close File](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/r62qox7kj40h6vb9rizy.gif)

### 11. Re-open a Closed File
You can reopen a previously closed file. When executed in succession, you can go back and reopen files in order from the most recently closed one to the past.
This is recommended when you have closed a file by mistake or when you want to check a file in the past.

![Re-open a Closed File Shortcut](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gwv4thku7otrf5new2t9.png)

![Re-open a Closed File](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bqt8xoz87vy4qvo4awwx.gif)

---
## Summary

If you want to learn more about VSCode shortcuts, check the following cheatsheets from the official website.
For Windows: https://code.visualstudio.com/shortcuts/keyboard-shortcuts-windows.pdf
For Mac: https://code.visualstudio.com/shortcuts/keyboard-shortcuts-macos.pdf

---
## About Us 💡
In addition, we want to introduce a little more about GROWI, an open software developed by _WESEEK, Inc._

_GROWI_ is a wiki service with features-rich support for efficient information storage within the company. It also boasts high security and various authentication methods are available to simplify authentication management, including LDAP/OAuth/SAML.

GROWI originated in Japan and **GROWI OSS** is **FREE** for anyone to [download](https://docs.growi.org/en/admin-guide/?utm_source=dev+community+&utm_medium=referral&utm_campaign=11_Useful_VSCode_Shortcuts_For_More_Comfortable_Development) and use in **English**.

For more information, go to [GROWI.org](https://growi.org/en/?utm_source=dev+community+&utm_medium=referral&utm_campaign=11_Useful_VSCode_Shortcuts_For_More_Comfortable_Development) to learn more about us. 

![GROWI.org](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xqhifh7sj8oz7n96y6aj.png)