[Vue warn]: Cannot find element: #app

【报错原因】

1. 把对应js放在了head标签里面,页面没有加载完成就进行渲染,导致找不到#app。
2.加了<template></template>标签

【解决方案】

1.把标签放到body后面
2.去除<template></template>标签

Vue——报错总结的更多相关文章

  1. Vue报错——“Trailing spaces not allowed”

    在VSCode中开发Vue 报错:“Trailing spaces not allowed” 这是空格多了,删除多余的空格就可以了

  2. vue 报错 :属性undefined(页面成功渲染)

    vue 报错:Cannot read property 'instrumentId' of undefined" 相关代码如下: <template> ... <span& ...

  3. Vue 报错Error in render: “TypeError: Cannot read properties of null (reading ‘xxx’)” found in

    前端vue报错 [Vue warn]: Error in render: "TypeError: Cannot read properties of null (reading 'name' ...

  4. Vue报错 type check failed for prop “xxx“. Expected String with value “xx“,got Number with value ‘xx‘

    vue报错    [Vue warn]: Invalid prop: type check failed for prop "name". Expected String with ...

  5. Vue报错: Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'protocol')

    Vue报错: Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'protocol') 报错信 ...

  6. vue报错Error in render: "TypeError: Cannot read property '0' of undefined"

    通常有两种情况: 1.在模板的html标签上使用length报错 vue 中使用 length判断的时候,有时会报错,如下: <div class="item_list" v ...

  7. vue报错信息

    1.Property or method "xxx" is not defined on the instance but referenced during render. 原因 ...

  8. 配置webpack loader vue 报错:Module build failed: TypeError: this._init is not a function

    单文件组件 引入时报错 配置webpage.config.js中的vue 需要如下写法 { test: /\.vue/, loader: "vue-loader", } 之前写的l ...

  9. Vue报错:Uncaught TypeError: Cannot assign to read only property’exports‘ of object’#<Object>‘的解决方法

    发现问题 运行一下以前的一个Vue+webpack的 vue仿新闻网站  小项目,报错 由于自己vue学习不深入,老是这个报错,找了好久(确切的说是整整一下午^...^)才找到原因 -v- Uncau ...

随机推荐

  1. 德国慕尼黑.NET俱乐部VS2019发布活动

    就在广州.NET俱乐部紧锣密鼓的准备配合VS2019发布搞一场大Party的时候,德国慕尼黑.NET俱乐部早就已经对外宣布他们将会配合VS2019发布搞两场活动,注意,是两场哦,不是一场哦. 第一场是 ...

  2. WebLogic使用总结

    一. WebLogic安装 WebLogic使用总结(一)——WebLogic安装 一.下载WebLogic 到Oracle官网http://www.oracle.com/ 下载WebLogic(根据 ...

  3. 微信小程序(五) 利用模板动态加载数据

    利用模板动态加载数据,其实是对上一节静态数据替换成动态数据:

  4. android FragmentTabhost导航分页

    基本模板 public class MainActivity extends FragmentActivity { private FragmentTabHost mTabHost; private ...

  5. php+ajax实现登录按钮加载loading效果

    php+ajax实现登录按钮加载loading效果,一个提高用户体验,二个避免重复提交表单,ajax判断加载是否完成. 登录表单 <form onsubmit="return chec ...

  6. 转一篇OpenSSL的例子:简单的TLS服务器

    原名:Simple TLS Server 原址:https://wiki.openssl.org/index.php/Simple_TLS_Server Windows下就不要从源码编译OpenSSL ...

  7. Actor模型浅析 一致性和隔离性

    一.Actor模型介绍 在单核 CPU 发展已经达到一个瓶颈的今天,要增加硬件的速度更多的是增加 CPU 核的数目.而针对这种情况,要使我们的程序运行效率提高,那么也应该从并发方面入手.传统的多线程方 ...

  8. MySQL 基础知识梳理学习(二)----记录在页面层级的组织管理

    1.InnoDB的数据存储结构 InnoDB中数据是通过段.簇.页面构成的. (1)段是表空间文件中的主要组织结构,它是一个逻辑概念,用来管理物理文件,是构成索引.表.回滚段的基本元素.创建一个索引( ...

  9. Elasticsearch 安装操作手册

    第一部分 ES安装环境的准备和初始化 现在交心的版本Elasticsearch 5.6.3 官方建议安装Oracle的JDK8,安装前先检查机器是否已安装JDK. Step 1 检查环境机器是否已安装 ...

  10. selenium-判断元素是否可见(五)

    很多 case 在运行时都会出现页面还没加载完成,但是脚本已经跑完,并且报未找到元素 这是就需要增加判断,在预定的时间内如果页面显示了某元素后再让脚本继续执行,则为判断元素是否可见或者说页面是否显示了 ...