main.js 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. import Vue from 'vue';
  2. import App from './App';
  3. // 弹出框
  4. import pubc from '@/common/public.js'
  5. // 多语言本地化
  6. import VueI18n from 'vue-i18n'
  7. import messages from './locale/index'
  8. import ClUni from "@/uni_modules/cl-uni";
  9. import emoji from "./common/emoji.js"
  10. Vue.prototype.emoji = emoji
  11. Vue.use(ClUni);
  12. let i18nConfig = {
  13. locale: uni.getLocale(),
  14. messages
  15. }
  16. Vue.use(VueI18n)
  17. const i18n = new VueI18n(i18nConfig)
  18. Vue.config.productionTip = false
  19. Vue.prototype.$apiHost = 'http://e.yujianmate.com/Gapi'; //审核包
  20. // Vue.prototype.$apiHost = '/api/Gapi';
  21. // Vue.prototype.$apiHost = 'https://storygarden.cn/Gapi'; //审核包
  22. // Vue.prototype.$apiHost = 'https://duoxiaoduoxue.com/Gapi'; //正式包
  23. // Vue.prototype.$apiHost = 'http://192.168.2.154:11070/Gapi';
  24. // Vue.prototype.now = Date.now || function () {
  25. // return new Date().getTime();
  26. // };
  27. Vue.prototype.isArray = Array.isArray || function(obj) {
  28. return obj instanceof Array;
  29. };
  30. App.mpType = 'app'
  31. const app = new Vue({
  32. i18n,
  33. ...App
  34. })
  35. app.$mount()