38 lines
777 B
JavaScript
38 lines
777 B
JavaScript
|
|
// #ifndef VUE3
|
|
import Vue from 'vue'
|
|
import App from './App'
|
|
import api from './utils/api'
|
|
import check from './utils/check'
|
|
import config from './utils/config.js'
|
|
|
|
Vue.prototype.$api = api
|
|
Vue.prototype.$check = check
|
|
Vue.prototype.$config = config
|
|
Vue.config.productionTip = false
|
|
|
|
App.mpType = 'app'
|
|
|
|
const app = new Vue({
|
|
...App
|
|
})
|
|
app.$mount()
|
|
// #endif
|
|
|
|
// #ifdef VUE3
|
|
import { createSSRApp } from 'vue'
|
|
import App from './App.vue'
|
|
import api from './utils/api'
|
|
import check from './utils/check'
|
|
import config from './utils/config.js'
|
|
|
|
export function createApp() {
|
|
const app = createSSRApp(App)
|
|
app.config.globalProperties.$api = api
|
|
app.config.globalProperties.$check = check
|
|
app.config.globalProperties.$config = config
|
|
return {
|
|
app
|
|
}
|
|
}
|
|
// #endif
|