main.js 971 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  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 mixin from './utils/mixin.js'
  8. Vue.config.ignoredElements.push("wx-open-subscribe") ;
  9. Vue.prototype.carhelp=mixin
  10. // 先运行yarn 初始化
  11. import Vconsole from 'vconsole'
  12. //import './router' // 引入路由
  13. import router from './bobo-router'
  14. // main.js
  15. // 先运行yarn 初始化
  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. } ,methods:{
  32. gotoUrl(url){
  33. uni.navigateTo({
  34. url:"/"+url
  35. })
  36. }
  37. }
  38. })
  39. app.$mount()