解决办法:
打开你router目录下的index.js文件,复制下面代码,添加到最下方就可以了。
const originalPush = Router.prototype.push
Router.prototype.push = function push(location) {
return originalPush.call(this, location).catch(err => err)
}
解决办法:
打开你router目录下的index.js文件,复制下面代码,添加到最下方就可以了。
const originalPush = Router.prototype.push
Router.prototype.push = function push(location) {
return originalPush.call(this, location).catch(err => err)
}