main.js 653 B

12345678910111213141516171819202122
  1. import { createApp } from 'vue'
  2. import 'element-plus/dist/index.css'
  3. import ElementPlus from 'element-plus'
  4. import zhCn from 'element-plus/es/locale/lang/zh-cn'
  5. // 引入gin-vue-admin前端初始化相关内容
  6. import './core/gin-vue-admin'
  7. // 引入封装的router
  8. import router from '@/router/index'
  9. import { run } from '@/core/gin-vue-admin.js'
  10. import '@/permission'
  11. import { store } from '@/store/index'
  12. import { auth } from '@/directive/auth'
  13. import App from './App.vue'
  14. const app = createApp(App)
  15. run(app)
  16. auth(app)
  17. app.config.productionTip = false
  18. app.use(store).use(router).use(ElementPlus, { locale: zhCn }).mount('#app')
  19. export default app