代码优化

This commit is contained in:
dqjdda
2019-10-24 17:57:02 +08:00
parent 0429f86d6c
commit b40b781d0a
5 changed files with 16 additions and 16 deletions

View File

@@ -16,7 +16,7 @@ import store from './store'
import '@/icons' // icon
import './router/index' // permission control
// import Router from 'vue-router'
import Router from 'vue-router'
Vue.use(mavonEditor)
Vue.use(permission)
@@ -24,10 +24,10 @@ Vue.use(dict)
Vue.use(ElementUI, { locale })
Vue.config.productionTip = false
// const routerPush = Router.prototype.push
// Router.prototype.push = function push(location) {
// return routerPush.call(this, location).catch(error => error)
// }
const routerPush = Router.prototype.push
Router.prototype.push = function push(location) {
return routerPush.call(this, location).catch(error => error)
}
require('babel-polyfill')
new Vue({