main.js 826 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. import App from './App'
  2. // import audio from "./common/audio.js";
  3. // #ifndef VUE3
  4. import Vue from 'vue'
  5. import './uni.promisify.adaptor'
  6. Vue.config.productionTip = false
  7. // 卡片配置来源 server:服务器获取 local:本地获取
  8. // Vue.prototype.$cardconfigType = "server";
  9. Vue.prototype.$cardconfigType = "local";
  10. // Vue.prototype.$audio = audio;
  11. App.mpType = 'app'
  12. const app = new Vue({
  13. ...App
  14. })
  15. app.$mount()
  16. // #endif
  17. // #ifdef VUE3
  18. import { createSSRApp } from 'vue'
  19. export function createApp() {
  20. const app = createSSRApp(App)
  21. // 卡片配置来源 server:服务器获取 local:本地获取
  22. app.config.globalProperties.$cardconfigType = "server";
  23. // app.config.globalProperties.$cardconfigType = "local";
  24. // app.config.globalProperties.$audio = audio;
  25. return {
  26. app
  27. }
  28. }
  29. // #endif