使用el-dialog時,報錯“Unknown custom element: did you register the component correctly?...make sure to provide the 'name' option”


初學vue時,曾遇到一個無語的問題,在用el-dialog時一直顯示沒有導入,結果發現是因為沒有把element ui引入到項目里。
需進行以下步驟:
1.執行:
npm install element-ui -s
 
2.在main.js文件里加入以下代碼:
 
import ElementUI from 'element-ui' import 'element-ui/lib/theme-default/index.css' Vue.use(ElementUI)
 
3.完成以上步驟,即可正常用element ui的東西了。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



猜您在找 Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. found in Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. found in ]: Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option.解決方法 Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. vue報錯[Vue warn]: Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. vue引入組建報錯Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. found in VUE報錯解決方法 Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. at src/views/index/"> [Vue warn]: Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option. found in ---> at src/views/index/ [Vue warn]: Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option.問題的解決方法 vue組件注冊錯誤:Unknown custom element: - did you register the component correctly? For recursive components, make sure to provide the "name" option.
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM