手机建站平台哪个好,全网霸屏整合营销推广,wordpress置顶到首页,河北省造价信息价查询前言#xff1a;在做vue项目时#xff0c;有时代码没有报错#xff0c;但运行时却各种问题#xff0c;没有报错排查起来就很费劲#xff0c;本人感悟#xff1a;写前端#xff0c;需要好的眼神#xff01;#xff01;#xff01;谨以此博客记录下自己的踩坑点。 一、… 前言在做vue项目时有时代码没有报错但运行时却各种问题没有报错排查起来就很费劲本人感悟写前端需要好的眼神谨以此博客记录下自己的踩坑点。 一、Failed to resolve componentXXX
Main.vue:42 [Vue warn]: Failed to resolve component: lable If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement.
原因在于label标签我写成了lable 看了这两篇博客找到的问题虽然自己看了好久确实是没注意label这个标签初学者的坑题外话前端也太坑了哪里错了也没有提示总是在后面才告诉你有奇奇怪怪的问题
关于Vue3的一个奇怪的警告Failed to resolve component: dir If this is a native custom element_qq_32021429的博客-CSDN博客
【前端】vue Failed to resolve component If this is a native custom element, make sure to exclude it from component resolution via compilerOptions.isCustomElement. - 淡怀 - 博客园 (cnblogs.com)
总结遇到此类问题检查后面的XXX是不是有这个标签检查标签名是不是写对了。
二、undefined问题
明明定义了但在console里没有输出内容 请看代码
这里用的是caseKey 但到这里用的却是casekey能一样吗 总结遇到undefined问题检查一下变量名是不是写对了细心点代码不会有错误提示但在运行起来时会告诉你没有定义