index.ts 548 B

1234567891011121314151617
  1. import { createHead } from '@vueuse/head'
  2. // import ElementPlus from 'element-plus'
  3. import 'virtual:svg-icons-register'
  4. import { VabIcon } from 'vsv-icon'
  5. import type { App } from 'vue'
  6. import './styles/vab.scss'
  7. export const setupVab = (app: App<Element>) => {
  8. // app.use(ElementPlus)
  9. app.use(createHead())
  10. app.component('VabIcon', VabIcon)
  11. const Plugins = import.meta.glob('./plugins/*.ts', { eager: true })
  12. Object.getOwnPropertyNames(Plugins).forEach((key) => {
  13. const plugin: any = Plugins[key]
  14. app.use(plugin.default)
  15. })
  16. }