mes_mobile/main.js

62 lines
1.6 KiB
JavaScript

import "./static/iconfont/iconfont.css"
import './static/css/app.css';
import "./static/iconfont/iconfont-weapp/iconfont-weapp-icon.css"
// 全局组件
import searchView from './components/searchView/index'
import loadMore from './components/loadMore/index'
import progressBar from './components/progressBar'
import pickerSelect from './components/pickerSelect/index'
import calendar from './components/calendar/index'
import uploadImg from './components/upload/uploadImg'
// #ifndef VUE3
import Vue from 'vue'
import App from './App'
import svg from './static/iconfont/svg.js'
Vue.component('search-view', searchView);
Vue.component('load-more', loadMore);
Vue.component('progress-bar', progressBar);
Vue.component('picker-select', pickerSelect);
Vue.component('calendar', calendar);
Vue.component('upload-img', uploadImg);
Vue.use(svg);
Vue.config.productionTip = false;
App.mpType = 'app';
const app = new Vue({
...App
})
app.$mount()
// #endif
// #ifdef VUE3
import { createSSRApp } from 'vue'
import App from './App.vue'
import request from "./utils/api.js"
import publicMethods from "./utils/public.js"
export function createApp() {
const app = createSSRApp(App)
// 全局注册组件
app.component('searchView', searchView);
app.component('loadMore', loadMore);
app.component('progressBar', progressBar);
app.component('pickerSelect', pickerSelect);
app.component('calendar', calendar);
app.component('uploadImg', uploadImg);
app.config.globalProperties.$api = request;
app.config.globalProperties.$wf = publicMethods;
return {
app
}
}
// #endif