投屏H5端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
859 B

5 years ago
  1. import Vue from 'vue';
  2. import App from './App';
  3. import mixin from '@/common/mixin.js';
  4. import * as API from '@/common/api.js';
  5. import * as $shared from '@/common/shared.js';
  6. Vue.config.productionTip = false;
  7. App.mpType = 'app';
  8. // 每个页面都会进入mixin
  9. Vue.mixin(mixin);
  10. // 将API注入全局
  11. Vue.prototype.API = API;
  12. // 全局共享方法
  13. Vue.prototype.$shared = $shared;
  14. // 引入全局uView
  15. import uView from 'uview-ui';
  16. Vue.use(uView);
  17. // 引入请求方法
  18. import { $http } from '@/common/http.js';
  19. Vue.prototype.$http = $http;
  20. // 将无数据组件注入全局
  21. import lfNocontent from '@/components/lf-nocontent/lf-nocontent.vue';
  22. Vue.component('lf-nocontent', lfNocontent);
  23. const app = new Vue({
  24. ...App
  25. });
  26. // 引入http拦截器
  27. import httpInterceptor from '@/common/http.interceptor.js';
  28. Vue.use(httpInterceptor, app);
  29. app.$mount();