import App from "./App"; import Vue from "vue"; import mixin from "@/mixin/index.js"; import utils from "@/utils/utils.js"; import api from "@/api/index.js"; import store from "@/store/index.js"; import uView from "@/uni_modules/uview-ui"; /* #ifdef H5 */ import { h5init } from "@/utils/h5init"; h5init() /* #endif */ const globalInformation = new Promise(async (resolve) => { resolve({ image: await api.common.getImages(), storeDetail: await api.common.getStoreDetail(), }) }).catch(e => { console.log(e); }) globalInformation.then(({ image, storeDetail }) => { store.dispatch("setData", { key: "$Gimage", val: image.data }) store.dispatch("setData", { key: "$GstoreDetail", val: storeDetail.data }) }) Vue.use(uView); Vue.mixin(mixin); Vue.config.productionTip = false; App.mpType = "app"; Vue.prototype.$utils = utils; Vue.prototype.$api = api; const app = new Vue({ store, ...App, }); app.$mount();