main.js 656 B

12345678910111213141516171819202122232425262728293031
  1. import App from './App'
  2. import api from '@/apis/api.js'
  3. import common from '@/common/js/common.js'
  4. import uView from "uview-ui";
  5. import verify from './common/graceChecker.js' //数据校验证
  6. import http from './common/http.js'
  7. Vue.use(uView);
  8. // #ifndef VUE3
  9. import Vue from 'vue'
  10. Vue.config.productionTip = false
  11. App.mpType = 'app'
  12. Vue.prototype.$api = api
  13. Vue.prototype.$common = common
  14. Vue.prototype.verify = verify;
  15. Vue.prototype.http = http;
  16. const app = new Vue({
  17. ...App
  18. })
  19. app.$mount()
  20. // #endif
  21. // #ifdef VUE3
  22. import { createSSRApp } from 'vue'
  23. export function createApp() {
  24. const app = createSSRApp(App)
  25. return {
  26. app
  27. }
  28. }
  29. // #endif