cloudroam
7 天以前 c31a8def0ac90d86b8e8e345441bd28002a9ef2f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
import App from './App'
 
import uviewPlus from 'uview-plus'
import { createPinia } from 'pinia'
import message from './plugins/message'
import http from './plugins/http.js'
import storage from './plugins/storage.js'
// import store from './store/index.js'
 
import {
  createSSRApp
} from 'vue'
 
import topTabBar from '@/components/tabbar/top-tab-bar'
import customerFooter from '@/components/footer/customer-footer'
import sectionTitle from '@/components/title/section-title'
import sectionTitleBtn from '@/components/title/section-title-btn'
import commentItem from '@/components/comment/comment-item'
import commentSubItem from '@/components/comment/comment-sub-item'
import commentPopup from '@/components/comment/comment-popup'
import topTabs from '@/components/top-tabs.vue'
import flowCard from '@/components/card/flow-card.vue'
import './theme.scss'
 
export function createApp() {
  const app = createSSRApp(App)
 
  app.component('top-tab-bar', topTabBar)
  app.component('common-footer', customerFooter)
  app.component('section-title', sectionTitle)
  app.component('section-title-btn', sectionTitleBtn)
  app.component('comment-item', commentItem)
  app.component('comment-sub-item', commentSubItem)
  app.component('comment-popup', commentPopup)
  app.component('top-tabs', topTabs)
  app.component('flow-card', flowCard)
 
  app.use(uviewPlus)
 
  app.use(createPinia())
  
 // 全局属性
  app.config.globalProperties.$message = message
  app.config.globalProperties.$http = http
  app.config.globalProperties.$storage = storage
  // app.config.globalProperties.$store = store
 
  // uni.$u.setConfig({
  //   config: {
  //     unit: 'rpx'
  //   },
  //   props: {
  //     radio: {
  //       size: 32,
  //       labelSize: 32
  //     },
  //     picker: {
  //       confirmColor: '#20613D'
  //     },
  //     steps: {
  //       size: 32,
  //       fontSize: 32
  //     }
  //   }
  // })
 
// app.use(uviewPlus, () => ({
//   options: {
//     config: {
//       unit: 'rpx'
//     },
//     props: {
//       radio: {
//         size: 32,
//         labelSize: 32
//       },
//       picker: {
//         confirmColor: '#20613D'
//       },
//       steps: {
//         size: 32,
//         fontSize: 32
//       }
//     }
//   }
// }))
 
  return {
    app
  }
}