1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- import App from './App'
- import * as http from './utils/http' // http请求接口
- import * as utils from './utils/utils' // 工具文件
- import storage from 'utils/storage' // 缓存文件
- import config from '@/config' // 配置
- import MD5 from 'js-md5'
- import * as msg from './utils/msg' // 工具文件
- import _ from 'lodash'
- // import * as scanCode from '@/components/utils/scanCode'
- // ********** devapi *********
- import { DEVAPI } from "@/components/utils/scanCode"
- let devAPI = new DEVAPI()
- devAPI.initDevAPI()
- // import lodash
- Vue.prototype.$storage = storage
- Vue.prototype.$http = http
- Vue.prototype.$config = config
- Vue.prototype.$utils = utils
- Vue.prototype.$msg = msg
- // Vue.prototype.$scanCode = scanCode
- Vue.prototype.$md5 = MD5
- Vue.prototype.$scanAudio = uni.createInnerAudioContext();
- Vue.prototype.$devapi = devAPI; // 设备api
- Vue.prototype._ = _
- // #ifndef VUE3
- import Vue from 'vue'
- App.mpType = 'app'
- const app = new Vue({
- ...App
- })
- app.$mount()
- // #endif
- // #ifdef VUE3
- import { createSSRApp } from 'vue'
- export function createApp() {
- const app = createSSRApp(App)
- return {
- app
- }
- }
- // #endif
|