This commit is contained in:
2022-12-28 10:08:51 +08:00
parent 0fa93d545e
commit 3881370b6e
151 changed files with 17044 additions and 0 deletions

26
im/src/permission.js Normal file
View File

@@ -0,0 +1,26 @@
import router from '@/router'
import NProgress from 'nprogress'
import 'nprogress/nprogress.css'
import config from '@/config/config'
NProgress.configure({
showSpinner: false,
})
const WEBSITE_NAME = config.WEBSITE_NAME
router.beforeEach((to, from, next) => {
document.title = to.meta.title
? `${WEBSITE_NAME} | ${to.meta.title}`
: WEBSITE_NAME
NProgress.start()
next()
})
router.afterEach(() => {
NProgress.done()
})