main.ts 761 B

12345678910111213141516171819202122232425262728
  1. import { createApp } from 'vue'
  2. import { createPinia } from 'pinia'
  3. import App from './App.vue'
  4. import router, { setRouter } from './router'
  5. import '@/router/permission'
  6. import { View, Setting, User, Lock, Expand, Fold, Refresh, Camera, Microphone } from '@element-plus/icons-vue'
  7. import './assets/main.css'
  8. import 'element-plus/dist/index.css'
  9. const app = createApp(App)
  10. // 注册需要的图标组件
  11. app.component('View', View)
  12. app.component('Setting', Setting)
  13. app.component('User', User)
  14. app.component('Lock', Lock)
  15. app.component('Expand', Expand)
  16. app.component('Fold', Fold)
  17. app.component('Refresh', Refresh)
  18. app.component('Camera', Camera)
  19. app.component('Microphone', Microphone)
  20. app.use(createPinia())
  21. setRouter()
  22. app.use(router)
  23. app.mount('#app')