template-project/main.js

34 lines
1.1 KiB
JavaScript
Raw Normal View History

2022-03-28 10:40:02 +00:00
import Vue from 'vue';
import App from './App';
2022-04-07 10:14:28 +00:00
import store from './store'
Vue.prototype.$store = store
2022-03-28 10:40:02 +00:00
import nothingPage from './components/nothing/nothing-page.vue';//引入无内容组件
Vue.component('nothing-page',nothingPage);//全局注册无内容组件
import statusNav from './components/status-navs/status-nav.vue';//引入头部状态栏与导航栏组件
Vue.component('status-nav',statusNav);//全局注册头部状态栏与导航栏组件
import containerSubgroupTwo from './components/containers/container-subgroup-two.vue';//引入头部状态栏与导航栏组件
Vue.component('container-subgroup',containerSubgroupTwo);//全局注册头部状态栏与导航栏组件
2022-04-07 10:14:28 +00:00
// #ifdef MP-WEIXIN
2022-03-28 10:40:02 +00:00
import share from './jsFile/share.js';// 全局注册分享事件
Vue.mixin(share);
2022-04-07 10:14:28 +00:00
// #endif
2022-03-28 10:40:02 +00:00
2022-04-07 10:14:28 +00:00
// 常用便捷式公共方法
2022-03-28 10:40:02 +00:00
import tools from '@/jsFile/tools.js';
Vue.prototype.$toolAll = tools;
// 响应数据
import requst from '@/jsFile/requst.js';
Vue.prototype.$requst = requst;
App.mpType = 'app';
const app = new Vue({
2022-04-07 10:14:28 +00:00
store,
2022-03-28 10:40:02 +00:00
...App
})
app.$mount()