import Vue from 'vue' import App from './App' import store from './store' import '@/static/iconfont/iconfont.css' import { getDay,NumberHandle,formatNum,formateHours } from '@/config/common.js' import {show_init_loading,hide_init_loading,nav_back} from '@/config/uniInfo.js' import theEnd from '@/components/theEnd.vue' import noData from '@/components/noData.vue' Vue.component('noData',noData) Vue.component('theEnd', theEnd) Vue.config.productionTip = false Vue.prototype.$getDay = getDay; Vue.prototype.$formatNum = formatNum; Vue.prototype.$NumberHandle = NumberHandle; Vue.prototype.$formateHours = formateHours; Vue.prototype.$show_init_loading = show_init_loading Vue.prototype.$hide_init_loading = hide_init_loading Vue.prototype.$nav_back = nav_back Vue.prototype.$store = store //app.vue里的onLaunch中如果有异步方法,比如登录方法,返回结果可能会在页面的 onLoad 之后, // 为了让页面的 onLoad 在 onLaunch 之后执行 https://blog.csdn.net/weixin_39152200/article/details/109179581 Vue.prototype.$onLaunched = new Promise(resolve=>{ Vue.prototype.$isResolve = resolve }) // Vue.prototype.$backgroundAudioData = { // playing: false, // playTime: 0, // formatedPlayTime: '00:00:00' // } App.mpType = 'app' const app = new Vue({ store, ...App }) app.$mount()