vue多页面demo
No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.

29 líneas
523 B

hace 4 años
import Vue from 'vue'
import App from './App.vue'
hace 4 años
import router from '@/router'
hace 4 años
import store from '@/store'
Vue.config.productionTip = false
router.beforeEach((to, from, next) => {
if (!to.query.appId) {
if (from.query.appId) {
to.query.appId = from.query.appId
} else {
to.query.appId = window.location.href.match(/appId=(.*)/)[1]
}
}
next()
})
router.afterEach((to, from) => {
})
new Vue({
router,
store,
render: h => h(App)
}).$mount('#app')