main.js 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. import Vue from 'vue'
  2. import App from './App'
  3. //import MyCommon from '@/components/Common.vue'
  4. //import CarLoading from '@/components/Loading.vue'
  5. import getOpenId from './utils/init.js'
  6. getOpenId.init()
  7. import 'remixicon/fonts/remixicon.css'
  8. import mixin from './utils/mixin.js'
  9. Vue.config.ignoredElements.push("wx-open-subscribe") ;
  10. Vue.prototype.carhelp=mixin
  11. import Vconsole from 'vconsole'
  12. //import './router' // 引入路由
  13. import router from './bobo-router'
  14. window.wx = {}
  15. // main.js
  16. import uView from "uview-ui";
  17. Vue.use(uView);
  18. Vue.config.productionTip = false
  19. App.mpType = 'app'
  20. const app = new Vue({
  21. ...App
  22. })
  23. //Vue.component('my-common',MyCommon)
  24. //Vue.component('car-loading',CarLoading)
  25. //Vue.use(mixin)
  26. Vue.mixin({
  27. onLoad( option){
  28. if (option.test == 'test') {
  29. let vConsole = new Vconsole()
  30. }
  31. this.projectName = process.car.ProjectName;
  32. this.branchParameter=process.car.branchParameter;
  33. } ,methods:{
  34. gotoUrl(url){
  35. uni.navigateTo({
  36. url:"/"+url
  37. })
  38. }
  39. }
  40. })
  41. app.$mount()