RuoYi-Vue3
中的vite-plugin-vue-setup-extend
用于解决vue3
下script setup
语法糖,手动设置组件name
不方便的问题。可能会导致vue
组件debuger
时, 断点位置不正确问题,(直至0.4.0版本依旧有该问题)。
目前的解决方案如下:
1、package.json
新增类型为commonjs
{
"name": "ruoyi",
"version": "3.8.6",
"description": "若依管理系统",
"author": "若依",
"license": "MIT",
"type": "commonjs",
}
2、vite-plugin-vue-setup-extend
替换为unplugin-vue-setup-extend-plus
"unplugin-vue-setup-extend-plus": "1.0.0"
3、vite\plugins\setup-extend.js
修改为unplugin-vue-setup-extend-plus/vite
import setupExtend from 'unplugin-vue-setup-extend-plus/vite'
export default function createSetupExtend() {
return setupExtend({})
}
powered by kaifamiao