通过vue add element引入的vue-cli-plugin-element
vue add element
vue create my-app cd my-app vue add element
提示错误 Unknown custom element: <el-button> - did you register the component correctly?应该怎么修改?vue-cli的版本,vue的版本是2.x
Unknown custom element: <el-button> - did you register the component correctly
你只是安装了依赖 但是没有引入组件 import ElementUI from 'element-ui';import 'element-ui/lib/theme-chalk/index.css';
Vue.use(ElementUI);
也可以按需引入 plugins里面应该有element.js
2.1m questions
2.1m answers
60 comments
57.0k users