首页
编程日记
mapreduce
vscode
html
pytorch
history
2024/9/18 20:55:31
解决Vue2移动端(H5)项目,手机打开项目侧滑或者按物理返回键,始终是走this.$router.go(-1)
一、原因前言 最近开发Vue2移动端(H5)项目,用手机打开项目侧滑或者按物理返回键,始终是走this.$router.go(-1),即相当于点击了浏览器的返回键的项目。目前想要的效果是:只要回到初始页面,点击返…
阅读更多...
前端的面试题
Class 与 Style 如何动态绑定? 对象语法: <div v-bind:class"{ active: isActive, text-danger: hasError }"></div> data: {isActive: true,hasError: false }数组语法: <div v-bind:class"[isActive ? acti…
阅读更多...
前端的面试题
Class 与 Style 如何动态绑定? 对象语法: <div v-bind:class"{ active: isActive, text-danger: hasError }"></div> data: {isActive: true,hasError: false }数组语法: <div v-bind:class"[isActive ? acti…
阅读更多...
前端路由 Hash 模式和 History 模式
在SPA单页面模式盛行,前后端分离的背景下,我们要弄清楚路由到底是个什么玩意,它可以帮助我们加深对于前端项目线上运作的理解。 而现在我们常见的路由实现方式,主要有两种,分别是history和hash模式。 理解 如何理解路…
阅读更多...