router
前端路由history与hash模式的简单实现
npm install
安装依赖
npm run server
开启本地服务器
修改static/index.js内的mode可查看对应mode的页面效果
在app.js内已有history模式对应的后端代码, 在history模式下刷新也不会404
前端路由history与hash模式的简单实现
npm install
安装依赖
npm run server
开启本地服务器
修改static/index.js内的mode可查看对应mode的页面效果
在app.js内已有history模式对应的后端代码, 在history模式下刷新也不会404