vben
authored
|
1
|
import { Router } from 'vue-router';
|
vben
authored
|
2
|
|
|
3
4
5
|
import { createProgressGuard } from './progressGuard';
import { createPermissionGuard } from './permissionGuard';
import { createPageLoadingGuard } from './pageLoadingGuard';
|
vben
authored
|
6
7
8
9
10
|
import { createTitleGuard } from './titleGuard';
import { createMessageGuard } from './messageGuard';
import { createScrollGuard } from './scrollGuard';
import { createHttpGuard } from './httpGuard';
import { createPageGuard } from './pageGuard';
|
vben
authored
|
11
|
import { createStateGuard } from './stateGuard';
|
vben
authored
|
12
|
|
|
13
|
export function createGuard(router: Router) {
|
vben
authored
|
14
|
createPageGuard(router);
|
vben
authored
|
15
|
createPageLoadingGuard(router);
|
vben
authored
|
16
17
18
19
|
createHttpGuard(router);
createScrollGuard(router);
createMessageGuard(router);
createTitleGuard(router);
|
vben
authored
|
20
|
createProgressGuard(router);
|
|
21
|
createPermissionGuard(router);
|
vben
authored
|
22
|
createStateGuard(router);
|
|
23
|
}
|