Doc: improve iframe load speed
This commit is contained in:
@@ -18,7 +18,7 @@ Vue.use(VueRouter);
|
||||
const routesConfig = routes(true);
|
||||
routesConfig.push({
|
||||
path: '/',
|
||||
component: DemoList.default || DemoList
|
||||
component: DemoList
|
||||
});
|
||||
const router = new VueRouter({
|
||||
mode: 'history',
|
||||
@@ -33,6 +33,12 @@ router.beforeEach((to, from, next) => {
|
||||
next();
|
||||
});
|
||||
|
||||
router.afterEach(() => {
|
||||
window.syncPath();
|
||||
});
|
||||
|
||||
window.vueRouter = router;
|
||||
|
||||
new Vue({ // eslint-disable-line
|
||||
render: h => h(App),
|
||||
router
|
||||
|
||||
Reference in New Issue
Block a user