export interface Runtime {
    app: Ref<PlusRuntimeWidgetInfo>
}

export function useRuntime(): Runtime {
    const app = ref<PlusRuntimeWidgetInfo>({})

    onMounted(() => {
        // 获取应用信息
        // #ifdef APP-PLUS
        plus.runtime.getProperty(plus.runtime.appid, (info) => {
            app.value = info
        })
        // #endif
    })

    return {
        app,
    }
}
