当前位置:网站首页>router---mode
router---mode
2022-08-04 13:03:00 【monstkl】
One, hash mode
The default mode is hash modePrinciple: window.onhashchange eventIt is not the real page address, but is passed to the single-page file in the form of parameters. Just make sure that the file path of index.html is real.
Second, history mode
new Router({mode: 'history',routes: []})Principle: window.history.pushState completes URL jumping, this mode requires back-end support, because custom paths such as http://xxx/ are not available in single-page applicationsBack-end support mode 1:The server needs to add candidate resources for all cases so that they all return the same index.html fileBack-end support mode 2:Add a simple fallback route on the server, if the URL does not match any static resources, serve the index.html file
边栏推荐
- odoo13笔记点
- Cool and efficient data visualization big screen, it's really not that difficult to do!丨Geek Planet
- [UML] Summary of Information System Analysis and Design Knowledge Points
- 面试官:说一下NIO和BIO的区别
- The head module of the yolo series
- 《社会企业开展应聘文职人员培训规范》团体标准在新华书店上架
- DateTimeFormatter api
- Js获取当前页面url参数
- 【软考 系统架构设计师】软件架构设计② 软件架构风格
- Motion Rule (16)-Union Check Basic Questions-Relations
猜你喜欢
“蔚来杯“2022牛客暑期多校训练营2 G、J、K
nVisual二次开发——第二章 nVisual API操作指南Swagger使用
双目立体视觉笔记(二)
跨链桥已成行业最大安全隐患 为什么和怎么办
Ceres库运行,模板内报内存冲突问题。(已解决)
项目里的各种配置,你都了解吗?
用过Apifox这个API接口工具后,确实感觉postman有点鸡肋......
rpm安装提示error: XXX: not an rpm package (or package manifest):
"Lonely Walking on the Moon" is a powerful medicine, it can't cure the internal friction of happy twist
COMSOL空气反应 模型框架
随机推荐
Django使用腾讯云发送短信并存入redis
【PHP实现微信公众平台开发—基础篇】第1章 课程介绍
JSX使用
Billboard
情人节浪漫3D照片墙【附源码】
【解决方案 三十一】Navicat数据库结构同步
Oracle 19c 单实例 19.3.0 升级到19.11.0 详细教程
工具函数---字符串处理
高手,云集在于REST、gRPC 和 GraphQL之间!
新消费、出海、大健康......电子烟寻找“避风港”
c#学习_第二弹
备份控制文件
永磁同步电机FOC驱动代码讲解
关于mysql join 的一些说明
Haproxy搭建web群集
判断密码是否包含键盘连续字母
d不要直接用转串
为什么密码云服务平台是云时代的必然之选?
5 cloud security management strategies enterprises should implement
持续交付(三)Jenkinsfile语法使用介绍