-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmain.js
48 lines (47 loc) · 918 Bytes
/
main.js
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
import App from './App'
import uView from '@/uni_modules/uview-ui'
Vue.use(uView)
// #ifndef VUE3
import Vue from 'vue'
import './uni.promisify.adaptor'
Vue.mixin({
data() {
return {}
},
onLoad() {
// #ifdef MP-WEIXIN
uni.showShareMenu({})
// #endif
},
onShareAppMessage(res) {
return {
title: '里派物业,快来看看吧!',
path: '/pages/index/index',
imageUrl: 'https://mp-773911e8-6917-4f03-9f50-e2393807e7c3.cdn.bspapp.com/cloudstorage/37e8fc22-7550-4d13-82d1-ff7f341fd8a1.png',
success: function(shareTickets) {
console.log(shareTickets + '成功');
},
fail: function(res) {
console.log(res + '失败');
}
}
}
})
Vue.config.productionTip = false
App.mpType = 'app'
const app = new Vue({
...App
})
app.$mount()
// #endif
// #ifdef VUE3
import {
createSSRApp
} from 'vue'
export function createApp() {
const app = createSSRApp(App)
return {
app
}
}
// #endif