1.  普通路由

const routes = [
{ path: '/index', component: index }
]

2. 重定向 redirect

const routes = [
{ path: '/', redirect: '/index'},
{ path: '/index', component: index }
]

3. 嵌套路由

const routes = [
{ path: '/index', component: index,
children: [
{ path: 'info', component: info}
]
}
]

4. 懒加载

const routes = [
{ path: '/index', component: () => import('@/views/index.vue')},
{ path: '/hello', component: () => import('@/views/hello.vue') }
]

最新文章

  1. ipad和iphone的适配
  2. python2.6.6安装Image模块
  3. 图解NodeJS【基于事件、回调的单线程高性能服务器】原理
  4. Nginx+Tomcat+Memcached负载均衡集群服务搭建
  5. EXTJS4.2 控件之Grid 行点击事件
  6. matlab vs python
  7. jquery图片播放插件Fancybox(灯箱)
  8. js深入研究之函数内的函数
  9. python之模块:decimal
  10. MySQL库表状态查询
  11. ORACLE-EXP和IMP方法介绍
  12. java 多线程(总结)
  13. Android 开发之v4库冲突问题解决方案说明
  14. Spring之bean的生命周期
  15. 20165223 学习基础和C语言基础调查
  16. mybatis 转义
  17. ZooKeeper是什么
  18. Python 语言之 map/reduce
  19. kubernetes集群搭建(3):master节点安装
  20. Android 手动调用 返回键

热门文章

  1. itextpdf5设置页眉页脚、生成页码
  2. 【Mysql】初识MySQL
  3. Swagger从入门到放弃
  4. git使用笔记(第一次)
  5. bert剪枝系列——Are Sixteen Heads Really Better than One?
  6. yield_from
  7. 接口测试Post和Get区别(面试题)
  8. window-Mysql下载安装
  9. LeetCode3-Longest_Substring_Without_Repeating_Characters
  10. LeetCode 120. Triangle三角形最小路径和 (C++)