芝麻web文件管理V1.00
编辑当前文件:/home/forge/stage.herta-bht.smartcon-survey.com/resources/js/app.ts
import './bootstrap'; import '../css/app.css'; import {createApp, DefineComponent, h} from 'vue'; import {createInertiaApp} from '@inertiajs/vue3'; import {ZiggyVue} from '../../vendor/tightenco/ziggy'; import '@fortawesome/fontawesome-free/css/all.css'; import {createPinia} from "pinia"; import DashboardLayout from "@/Layouts/DashboardLayout.vue"; const appName = import.meta.env.VITE_APP_NAME || 'Brand Tracker'; const pages = import.meta.glob('./Pages/**/*.vue') as Record
Promise<{ default: DefineComponent }>>; createInertiaApp({ title: (title) => `${title} - ${appName}`, resolve: async (name: string) => { let page = await pages[`./Pages/${name}.vue`](); const component = page.default; component.layout = component.layout || DashboardLayout; return component; }, setup({el, App, props, plugin}) { createApp({render: () => h(App, props)}) .use(plugin) .use(ZiggyVue) .use(createPinia()) .mount(el); }, progress: { color: '#4B5563', }, }).then(r => {});