Home > Development Tools > VSCode > body text

What is the shortcut key for formatting code in vscode?

angryTom
Release: 2019-11-04 15:34:31
Original
36059 people have browsed it

What is the shortcut key for formatting code in vscode?

What are the shortcut keys for formatting code in vscode

Visual Studio Code can use the following shortcut keys Format code:

● On Windows Shift Alt F

● On Mac Shift Option F

● On Ubuntu Ctrl Shift I

Implement automatic code formatting when saving:

1) File-[Preferences]-[Settings];

2) Search emmet.include;

3) Add the following statement in [Workspace Settings] under settings.json:

"editor.formatOnType": true,
"editor.formatOnSave": true
Copy after login

4) Just write any code for testing.

Related recommendations: "vscode usage tutorial"

The above is the detailed content of What is the shortcut key for formatting code in vscode?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template