visual studio code的使用
1、添加代碼片段
參考:https://blog.csdn.net/qq_36370731/article/details/83014439
2、在vscode上運(yùn)行Git
先打開vscode內(nèi)置的Git:F1,輸入Show built-in Extensions, 左側(cè)列表中找Git,然后啟用
配置git.path:在設(shè)置中搜索 git.path ,在用戶設(shè)置中修改 git.path 字段值,如果沒有該字段就自己添加,字段值是 Git的可執(zhí)行程序的路徑,\ 符號(hào)換成 /

3、vscode 格式化vue文件
參考:http://www.rzrgm.cn/mlw1814011067/p/9614795.html
4、vscode 設(shè)置 VUE 文件格式化標(biāo)簽屬性不換行
{ "vetur.format.defaultFormatter.html": "js-beautify-html", "vetur.format.defaultFormatterOptions": { "js-beautify-html": { "wrap_attributes": "auto" }, "prettyhtml": { "printWidth": 100, "singleQuote": false, "wrapAttributes": false, "sortAttributes": false } } }
參考:http://www.rzrgm.cn/sunjinggege/p/8809536.html
5、vscode同步插件
vscode 中按住 shift + alt + d 可下載。
參考:https://www.jianshu.com/p/c10ac793eec0、http://www.rzrgm.cn/chengfeng6/p/10567200.html
6、vscode禁止粘貼后自動(dòng)格式化
參考:https://blog.csdn.net/weixin_34247299/article/details/91443522
7、文件夾折疊并列顯示的問題
參考:https://blog.csdn.net/weixin_42162265/article/details/106207676
8、用中劃線分隔的變量名能一次選中
參考:http://www.rzrgm.cn/dxy9527/p/15028825.html
9、自動(dòng)生成文件頭部注釋和函數(shù)注釋
參考:http://www.rzrgm.cn/suRimn/p/10450372.html
10、格式化代碼改為4個(gè)空格縮進(jìn)
參考:http://www.rzrgm.cn/MySmallWorld/p/13564139.html
如果還是不行,看下項(xiàng)目有沒有 .editorconfig 文件,找下里面的 indent_size 配置改為 4 即可。

浙公網(wǎng)安備 33010602011771號(hào)