This extension wraps js-beautify to format your Scarpet Script.
This project is modifying based on Lonefy/vscode-JS-CSS-HTML-formatter under MIT license, new code of this project will under gpl-v3 license
- open
Context Menu
and chooseFormat Code
- shortcuts:
Alt+Shift+F
- CLI: Press
F1
, enterFormat Code
the upper 3 ways don't work for
Javascript
&JSON
aftervscode v0.10.10
, but you can still formatCSS
andHTML
.
- CLI: Press
F1
,enterFormatter
-
Press
F1
, enterFormatter Config
, open the config file: -
Edit the file as your needs. This extension uses
js-beautify
internally, so you can edit the parameters whichjs-beautify
can use. -
Restart
vscode [!Important]
rjmacarthy, zhaopengme, Arrow7000, bitwiseman, Lonefy