|  |  | 
 |  |  | import App from './App' | 
 |  |  | import messages from './locale/index' | 
 |  |  |  | 
 |  |  | let i18nConfig = { | 
 |  |  |   locale: uni.getLocale(),// 获取已设置的语言 | 
 |  |  |   messages | 
 |  |  | } | 
 |  |  |  | 
 |  |  | // #ifndef VUE3 | 
 |  |  | import Vue from 'vue' | 
 |  |  | import VueI18n from 'vue-i18n' | 
 |  |  | Vue.use(VueI18n) | 
 |  |  | const i18n = new VueI18n(i18nConfig) | 
 |  |  |  | 
 |  |  | Vue.config.productionTip = false | 
 |  |  |  | 
 |  |  | import '@/common/bluetooth.js'; | 
 |  |  | 
 |  |  | Vue.prototype.$Mock = Mock; | 
 |  |  |  | 
 |  |  | App.mpType = 'app' | 
 |  |  |  | 
 |  |  |  | 
 |  |  | try { | 
 |  |  |   function isPromise(obj) { | 
 |  |  | 
 |  |  | } catch (error) { } | 
 |  |  |  | 
 |  |  | const app = new Vue({ | 
 |  |  |    i18n, | 
 |  |  |   ...App | 
 |  |  | }) | 
 |  |  | app.$mount() | 
 |  |  | 
 |  |  |  | 
 |  |  | // #ifdef VUE3 | 
 |  |  | import { createSSRApp } from 'vue' | 
 |  |  | import { createI18n } from 'vue-i18n' | 
 |  |  | const i18n = createI18n(i18nConfig) | 
 |  |  | export function createApp() { | 
 |  |  |   const app = createSSRApp(App) | 
 |  |  |   app.use(i18n) | 
 |  |  |   return { | 
 |  |  |     app | 
 |  |  |   } |