vue.js 625B

12345678910111213141516171819202122232425
  1. import { createApp, h } from 'vue'
  2. import { createInertiaApp } from '@inertiajs/inertia-vue3'
  3. import { InertiaProgress } from '@inertiajs/progress'
  4. import CoreuiVue from '@coreui/vue'
  5. import CIcon from '@coreui/icons-vue'
  6. import icons from '@/assets/icons'
  7. createInertiaApp({
  8. resolve: (name) => import(`./pages/${name}`),
  9. setup({ el, App, props, plugin }) {
  10. createApp({ render: () => h(App, props) })
  11. .use(plugin)
  12. .use(CoreuiVue)
  13. .mixin({ methods: { route } })
  14. .provide('icons', icons)
  15. .component('CIcon', CIcon)
  16. .mount(el)
  17. },
  18. })
  19. InertiaProgress.init({
  20. color: '#eb4432',
  21. })