当前位置:网站首页>Auto format when saving vscode configuration file

Auto format when saving vscode configuration file

2022-06-10 00:19:00 Half a lifetime

List of articles


install vetur(vue) and prettier Two plug-ins

First step :
To open the first vscode Software , Click settings in the lower left corner → Open Settings → Search settings
The second step :
Next, set the auto save file , Search box input files.autoSave, Select the setting item attribute as onFocuschange.
 Insert picture description here

The third step :
Enter... In the search settings box editor.defaultFormatter, Select the configuration item as Vetur.
 Insert picture description here

Enter... In the search settings box defaultFormatter, The following style formatting plug-ins can be freely selected :
 Insert picture description here

Step four :
Set up Prettier Automatically format the code when saving the plug-in , Search box input editor.formatOnSave, Items to be searched Hook that will do
 Insert picture description here Saved examples
 Insert picture description here

原网站

版权声明
本文为[Half a lifetime]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/160/202206091639503730.html