main.js 518 B

123456789101112131415161718192021222324252627282930
  1. import App from './App'
  2. // #ifndef VUE3
  3. import Vue from 'vue'
  4. import './uni.promisify.adaptor'
  5. Vue.config.productionTip = false
  6. App.mpType = 'app'
  7. const app = new Vue({
  8. ...App
  9. })
  10. app.$mount()
  11. // #endif
  12. import uviewPlus from '@/uni_modules/uview-plus'
  13. // #ifdef VUE3
  14. import {
  15. createSSRApp
  16. } from 'vue'
  17. import * as Pinia from 'pinia';
  18. export function createApp() {
  19. const app = createSSRApp(App)
  20. app.use(Pinia.createPinia());
  21. app.use(uviewPlus)
  22. return {
  23. app,
  24. Pinia
  25. }
  26. }
  27. // #endif