vue3中使用ant-design-vue
创建项目后
安装antdesign
npm i --save ant-design-vue@next
main.js中添加引用
import { createApp } from 'vue' import Antd from 'ant-design-vue'; import 'ant-design-vue/dist/antd.css'; const app = createApp(App) app.use(Antd);
vue3引用ant-design-vue编译运行时,可能会报错can't read property undefine错误
执行下面命令就行
npm i --save ant-design-vue@next -S