main.js 557 B

123456789101112131415161718192021222324252627282930313233
  1. import App from './App'
  2. // import {post} from "http/request.post.js"
  3. import store from './store'
  4. // #ifndef VUE3
  5. import Vue from 'vue'
  6. Vue.config.productionTip = false
  7. App.mpType = 'app'
  8. const app = new Vue({
  9. store,
  10. ...App
  11. })
  12. import uView from "uview-ui";
  13. Vue.use(uView)
  14. uni.$u.config.unit = 'rpx'
  15. // Vue.prototype.request=post
  16. require('./http/request.js')(app)
  17. app.$mount()
  18. // #endif
  19. // #ifdef VUE3
  20. import { createSSRApp } from 'vue'
  21. export function createApp() {
  22. const app = createSSRApp(App)
  23. return {
  24. app
  25. }
  26. }
  27. // #endif
  28. // app.$mount()