VsCode中ctrl+s后会在当前目录下自动生成dist目录的方法
作者:辣辣的草莓酱 时间:2023-04-25 09:19:41
在VsCode
中ctrl+s
后会在当前目录下自动生成dist
目录
解决办法:关闭compile-hero
插件
在设置中搜索compile-hero
插件
关闭所有自动生成dist
目录的选项(如下图所示)
PS:下面看下vue项目Ctrl+s vscode代码自动格式化
前言
多人开发vue项目,代码风格形式不一
vscode保存代码,自动按照eslint规范格式化代码设置(vscode最新版配置)
vscode插件
首先vscode需要装一些vscode插件
ESLint、Vetur、Prettier-Code formatter、GitLens-Git supercharged
配置settings.json
打开settings.json,贴上配置,注意自己原有的vscode主题和字体等不要替换掉
打开方式
方式一:
1)文件 ------.>【首选项】---------->【设置】
2)搜索emmet.include;
3)在settings.json下的【工作区设置】中添加
方式二:
Ctrl + P 搜索settings.json
贴上如下配置
{
"window.zoomLevel": 0,
"diffEditor.ignoreTrimWhitespace": false,
"workbench.colorTheme": "One Monokai",
"editor.fontSize": 14,
"workbench.editor.enablePreview": true, //预览模式关闭
"editor.formatOnSave": true, // #每次保存的时候自动格式化
// 自动修复
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true,
},
"eslint.enable": true, //是否开启vscode的eslint
// vscode默认启用了根据文件类型自动设置tabsize的选项
"editor.detectIndentation": false,
// 重新设定tabsize
"editor.tabSize": 2,
// #去掉代码结尾的分号
"prettier.semi": false,
// #使用单引号替代双引号
"prettier.singleQuote": true,
// #让prettier使用eslint的代码格式进行校验
"prettier.eslintIntegration": true,
"javascript.preferences.quoteStyle": "double",
"typescript.preferences.quoteStyle": "double",
// #让函数(名)和后面的括号之间加个空格
"javascript.format.insertSpaceBeforeFunctionPare
来源:https://blog.csdn.net/weixin_38233549/article/details/108226135
标签:VsCode,dist,目录,自动格式化
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
如何利用Python随机从list中挑选一个元素
2023-08-04 00:05:54
关于window.opener的用法
2008-02-23 11:03:00
使SQL用户只能看到自己拥有权限的库(图文教程)
2024-01-27 11:07:27
![](https://img.aspxhome.com/file/2023/6/129296_0s.png)
python3 配置logging日志类的操作
2021-04-22 20:15:09
![](https://img.aspxhome.com/file/2023/3/98853_0s.jpg)
详解在Python中以绝对路径或者相对路径导入文件的方法
2021-10-09 19:37:24
![](https://img.aspxhome.com/file/2023/5/103635_0s.png)
Python列表切片操作实例总结
2023-01-30 16:06:57
python 利用turtle库绘制笑脸和哭脸的例子
2022-01-16 08:35:30
![](https://img.aspxhome.com/file/2023/7/86157_0s.jpg)
IDEA 2020 设置项目集成git 及svn和git之间的切换问题
2022-11-23 20:02:14
![](https://img.aspxhome.com/file/2023/0/132360_0s.jpg)
Linux下利用python实现语音识别详细教程
2022-07-13 15:11:55
![](https://img.aspxhome.com/file/2023/7/65377_0s.png)
在asp中调用sql server的存储过程方法
2007-08-13 13:28:00
![](https://img.aspxhome.com/file/UploadPic/up/2007081313422835.jpg)
Python实现进程同步和通信的方法
2023-08-30 04:21:45
Java数据库连接池之c3p0简介_动力节点Java学院整理
2024-01-19 18:16:03
![](https://img.aspxhome.com/file/2023/7/88167_0s.jpg)
ASP使用MYSQL数据库全攻略
2009-11-08 18:27:00
python 判断参数为Nonetype类型或空的实例
2021-03-21 07:15:17
python多进程程序打包成exe的问题
2023-08-07 13:39:03
Yii2基于Ajax自动获取表单数据的方法
2023-11-21 00:59:56
Python特效之文字成像方法详解
2021-08-09 09:34:06
![](https://img.aspxhome.com/file/2023/8/68348_0s.jpg)
Golang解析JSON遇到的坑及解决方法
2024-05-10 13:58:29
Python异常学习笔记
2021-03-24 01:33:33
新手入门Mysql--sql执行过程
2024-01-25 11:21:37
![](https://img.aspxhome.com/file/2023/9/124079_0s.jpg)