错误信息:
源码:
import header from "./components/header"
import aside from "./components/aside"
import footer from "./components/footer"
export default {
name: 'layout',components: {
header: header,aside: aside,footer: footer
}
}
原因:
修改方案:
import header from "./components/header"
import aside from "./components/aside"
import footer from "./components/footer"
export default {
name: 'layout',components: {
'v-header': header,'v-aside': aside,'v-footer': footer
}
}
修复结果: ok!
以上这篇解决vue 引入子组件报错的问题就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持编程之家。
原文链接:https://www.f2er.com/vue/30394.html