This repository was archived by the owner on Sep 28, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 220
/
Copy pathmain.js
71 lines (61 loc) · 1.75 KB
/
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import Vue from 'vue'
import axios from 'axios'
import BootstrapVue from 'bootstrap-vue'
import PerfectScrollbar from 'vue2-perfect-scrollbar'
import SocialSharing from 'vue-social-sharing'
import Toasted from 'vue-toasted'
import vClickOutside from 'v-click-outside'
import vueTopprogress from 'vue-top-progress'
import VuePlyr from 'vue-plyr'
import VueI18Next from '@panter/vue-i18next'
import dayjs from 'dayjs'
import App from './App.vue'
import router from './router'
import store from './store'
import Register from './components/register'
import i18next from './i18n.config'
import 'dayjs/locale/en'
import 'dayjs/locale/fr'
import './external_links.js'
import 'bootstrap-vue/dist/bootstrap-vue.css'
import 'vue2-perfect-scrollbar/dist/vue2-perfect-scrollbar.css'
import 'vue-plyr/dist/vue-plyr.css'
dayjs.locale(window.electron.currentLocale())
Vue.config.productionTip = false
// // nodejs global proxy
// const proxy = window.electronstore.getProxySettings()
// if (proxy) {
// if (proxy.http) {
// process.env.http_proxy = proxy.http
// }
// if (proxy.https) {
// process.env.https_proxy = proxy.https
// }
// // window.globalagent.createGlobalProxyAgent({
// // environmentVariableNamespace: '',
// // forceGlobalAgent: true
// // })
// }
// ignore ssl error
process.env.NODE_TLS_REJECT_UNAUTHORIZED = '0'
Vue.use(BootstrapVue)
Vue.use(Toasted)
Vue.use(PerfectScrollbar)
Vue.use(SocialSharing)
Vue.use(vClickOutside)
Vue.use(VuePlyr)
Vue.use(vueTopprogress)
Vue.use(VueI18Next)
Vue.filter('t', value => {
if (!value) return ''
return i18n.t(value)
})
Register.registerComponents()
Vue.http = Vue.prototype.$http = axios
const i18n = new VueI18Next(i18next)
new Vue({
router,
store,
i18n: i18n,
render: h => h(App)
}).$mount('#app')