import { App, defineAsyncComponent } from 'vue'

const components = {
    AppPage: defineAsyncComponent(() => import("./page/index.vue")),
    AppView: defineAsyncComponent(() => import("./view/index.vue")),
}

const install = (app: App) => {
    for (const [key, value] of Object.entries(components)) {
        app.component(key, value); //注册全局组件
    }
};

export default {
    install,
}