【前端】vue Failed to resolve component If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
一、报错
runtime-dom.esm-bundler-daf7327a.js:1555 [Vue warn]: Failed to resolve component: myBtn
If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
at <App>
二、原因
核心原因就是因为报警告的这个组件(myBtn)没有注册
三、解决
3.1、有可能是setup写错了(手抖写成了steup)
3.2、名称错误
3.3、不用花括号
3.4、误写了多个components(会仅执行最后一个components)
如果忍耐算是坚强 我选择抵抗 如果妥协算是努力 我选择争取
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】博客园社区专享云产品让利特惠,阿里云新客6.5折上折
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步