You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
861 B

8 months ago
7 months ago
8 months ago
8 months ago
8 months ago
  1. import App from './App'
  2. // #ifndef VUE3
  3. import i18n from './locale/index.js'
  4. import Vue from 'vue'
  5. import './uni.promisify.adaptor'
  6. import 'config.js'
  7. Vue.config.productionTip = false
  8. App.mpType = 'app'
  9. import request from './utils/request'
  10. Vue.prototype.request = request
  11. import store from './store/index.js'
  12. import './plugin'
  13. import 'interceptor/interceptor.js'
  14. import sTabbar from '@/components/base/tabBar.vue'
  15. Vue.component("sTabbar", sTabbar)
  16. //后端返回数据格式过滤
  17. window.parseList = function(data) {
  18. if (!data) {
  19. return [];
  20. } else if (data.length || data.length == 0) {
  21. return data
  22. } else {
  23. return [data]
  24. }
  25. }
  26. const app = new Vue({
  27. ...App,
  28. i18n,
  29. store,
  30. })
  31. app.$mount()
  32. // #endif
  33. // #ifdef VUE3
  34. import {
  35. createSSRApp
  36. } from 'vue'
  37. export function createApp() {
  38. const app = createSSRApp(App)
  39. return {
  40. app
  41. }
  42. }
  43. // #endif