解决方法:在router文件夹的index.html文件修改
在Vue.use(VueRouter)前面添加字段如下:
const originalPush = VueRouter.prototype.push
VueRouter.prototype.push = function push(location) {
return originalPush.call(this, location).catch(err => err)
}
解决方法:在router文件夹的index.html文件修改
在Vue.use(VueRouter)前面添加字段如下:
const originalPush = VueRouter.prototype.push
VueRouter.prototype.push = function push(location) {
return originalPush.call(this, location).catch(err => err)
}