sunniejs / vue-h5-template

:tada:vue搭建移动端开发,基于vue-cli4.0+webpack 4+vant ui + sass+ rem适配方案+axios封装,构建手机端模板脚手架
https://sunniejs.github.io/vue-h5-template/
MIT License
3.08k stars 874 forks source link

fix: 🐛 修改编辑器引入unplugin-auto-import 的api,在编辑器红色报错提示 #122

Closed wcySpring closed 1 year ago

wcySpring commented 1 year ago

修改编辑器引入unplugin-auto-import 的api,在编辑器红色报错提示 现象:使用过程中会自动引入 Vue 相关组合 Api,是起作用的,但是 eslint 却报错 分析:起作用表示导入是正常可以用的,那么就是 eslint 的问题 解决:eslintrc 中 enabled 设置为 true,保存之后会随即在跟目录下生成 .eslintrc-auto-import.json 文件,然后将这个文件引入 .eslintrc.cjs 解决前: image 解决后: image

wcySpring commented 1 year ago

现象:vite-plugin-vue-setup-extend,导致source maps 失效 分析:vite-plugin-vue-setup-extend 是vben admin 作者的后期已经不维护,导致sourcemap失效,可参考vben2.90 版本已经将该插件移除 https://github.com/vbenjs/vue-vben-admin/blob/v2.9.0/build/vite/plugin/index.ts 解决:想继续使用改插件功能推荐使用 https://github.com/chenxch/vite-plugin-vue-setup-extend-plus,可以参考https://github.com/vbenjs/vue-vben-admin/pull/2288