其他分享
首页 > 其他分享> > 查漏补缺——Failed to mount component: template or render function not defined这个问题怎么解决?

查漏补缺——Failed to mount component: template or render function not defined这个问题怎么解决?

作者:互联网

问题

如题所示,控制台报错如下:

vue.esm.js?efeb:628 [Vue warn]: Failed to mount component: template or render function not defined.

found in

---> <HzhLayoutFooter> at F:\hzh\src\components\layout\hzh-layout-footer.vue
       <Hzh> at F:\hzh\src\App.vue
         <Root>

答案

vue报错 Failed to mount component: template or render function not defined.

hzh-layout-footer这个文件添加以下代码:

<template>
  
</template>

<script>
export default {

}
</script>

<style>

</style>

然后控制台就没有报错了。

标签:function,查漏,vue,render,defined,hzh,Failed,报错
来源: https://www.cnblogs.com/Huang-zihan/p/16399232.html