main.js 477 B

123456789101112131415161718192021222324252627282930
  1. import App from './App';
  2. // #ifndef VUE3
  3. import Vue from 'vue';
  4. import uView from 'uview-ui';
  5. import store from './store';
  6. Vue.use(uView);
  7. import '@/plugins/urequest';
  8. import '@/plugins/check-res';
  9. Vue.config.productionTip = false;
  10. App.mpType = 'app';
  11. const app = new Vue({
  12. store,
  13. ...App,
  14. });
  15. app.$mount();
  16. // #endif
  17. // #ifdef VUE3
  18. import {
  19. createSSRApp
  20. } from 'vue';
  21. export function createApp() {
  22. const app = createSSRApp(App);
  23. return {
  24. store,
  25. app,
  26. };
  27. }
  28. // #endif