Vue 2.x 中 路由当前页跳转到当前页 栈溢出
const originalReplace = Router.prototype.replace; Router.prototype.replace = function replace(location) { return originalReplace.call(this, location).catch(err => err); }; const originalPush = Router.prototype.push Router.prototype.push = function push(location) { return originalPush.call(this, location).catch(err => err) }
谢谢你这么好看,还来看我。如有问题,请联系我。

浙公网安备 33010602011771号