|
- import App from './App'
- import Vue from 'vue'
-
- import './uni.promisify.adaptor'
- Vue.config.productionTip = false
-
- App.mpType = 'app'
- // 引入uView2.0
- import uView from "uview-ui"
- Vue.use(uView)
- // 引入router
- import {
- router,
- RouterMount
- } from '@/router'
- Vue.use(router)
- // 引入vuex
- import store from '@/store'
- // 引入全局api
- import api from '@/api'
- import urls from '@/utils/pictureUrls.js'
- Vue.prototype.$api = api.api
- Vue.prototype.$baseUrl = api.baseUrl
- Vue.prototype.$themeColor = '#F3D4A3'
- Vue.prototype.$themeDeepColor = '#E19F4B'
-
- Vue.prototype.$urls = urls
- import util from 'utils/index.js'
- Vue.prototype.$util = util
- // #ifdef APP-PLUS
- // 请勿删除此代码块
- plus.runtime.quit = () => {
-
- };
- plus.nativeUI.toast = () => {
- return false;
- };
- // 请勿删除此代码块
- // #endif
-
- const app = new Vue({
- ...App,
- store
- })
- // uni-simple-router v1.3.5起 H5端 你应该去除原有的app.$mount();使用路由自带的渲染方式
- // #ifdef H5
- RouterMount(app, router, '#app')
- // #endif
-
- // #ifndef H5
- app.$mount(); //为了兼容小程序及app端必须这样写才有效果
- // #endif
|