Files
pupil/main.js
”chenxuelian“ b37ed47032 axios 封装
2022-12-24 16:44:08 +08:00

29 lines
563 B
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import App from './App'
//引入uView-ui组件库注意这两行要放在 import Vue 之后)
import uView from 'uview-ui'
import { apiService, toast } from "./service/request.js"
Vue.use(uView)
Vue.prototype.$apiServe = apiService
Vue.prototype.$toast= toast
// #ifndef VUE3
import Vue from 'vue'
Vue.config.productionTip = false
App.mpType = 'app'
const app = new Vue({
...App
})
app.$mount()
// #endif
// #ifdef VUE3
import { createSSRApp } from 'vue'
export function createApp() {
const app = createSSRApp(App)
return {
app
}
}
// #endif