解决方案 在二级路由的组件添加以上代码 component: {render(c) {return c('router-view')}}, 动态路由 动态菜单json { "code": "200", "msg": "成功", "data": [
npm 安装 npm i element-ui -S 在index.html文件中引入样式和组件库 <!-- 引入样式 --> <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk
Navigation.vue <template> <div class="title"> <span>爱奇艺</span> <span>点击即可查看本区标签的相关内容</span> <
1,param传参方式 nav.vue <template> <div class="title"> <span>热门标签</span> <span>点击即可查看本标签的内容</span>
错误信息描述 npm install ERROR in Cannot find module 'node-sass' Module build failed: Error: Node Sass version 6.0.1 is incompatible with ^4.0.0.Err
前言 WebSocket ,HTML5 开始提供的一种在单个 TCP 连接上进行全双工通讯的协议,其使用简单,应用场景也广泛,不同开发语言都用种类繁多的实现,仅Java体系中,Tomcat,Jetty,Spring等都提供了对WS的API支持。本篇不做理论探究,仅自娱自乐,简单实现网页版的聊天室功
1.1 移动端常用UI组件库 Vant Vant - Mobile UI Components built on Vue Cube UI cube-ui Document Mint UI http://mint-ui.github.io nut UI NutUI
安装 vuex npm install vuex --save 工程目录结构图 代码使用 Number.vue <template> <div> {{$store.state.num}} <br> <
注意,先下载 axios npm install axios 博客静态页面 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title></titl
1,默认插槽 子组件:<slot></slot> 子组件.vue <template> <div class="bili-grid"> <div class="bili-title">
1,在所在项目安装axios npm install axios -s import axios from 'axios'; 2,在config下修改index.js文件在proxyTable里加入后端目标地址 index.js 'use strict' // Template v
1,全局总线 a,在main.js里声明一个全局事件总线 beforeCreate(){ Vue.prototype.$bus=this;//声明一个全局事件总线 } b,school.vue <template> <div> <
如何使用配置 import{info,userMsg} from '../mixin.js' <template> <div> <h1>子组件</h1> <h1>{{msg}}</h1> &
1,props的三种接收方法 简单接收 子组件配置 <template> <div class="item"> <h2>{{title}}</h2> <p>{{content}}</p>
在vue中,通常情况下我们使用Google Chrome浏览器,和Firefox两种浏览器开发,因为vue官方只提供了这两种浏览器的调试开发工具。 一、在线安装方式(Vue Devtools) 1.选择Get Started 2.点击Get the Chrome Extension进行安装