mirror of
https://github.com/veops/cmdb.git
synced 2025-08-10 14:01:26 +08:00
前后端全面升级
This commit is contained in:
@@ -1,29 +1,41 @@
|
||||
// ie polyfill
|
||||
/* eslint-disable */
|
||||
import '@babel/polyfill'
|
||||
|
||||
import Vue from 'vue'
|
||||
import EventBus from './EventBus'
|
||||
import App from './App.vue'
|
||||
import router from './router'
|
||||
import store from './store'
|
||||
import i18n from './locales'
|
||||
import { VueAxios } from './utils/request'
|
||||
|
||||
import store from './store/'
|
||||
import bootstrap from './core/bootstrap'
|
||||
import './core/use'
|
||||
import './permission' // permission control
|
||||
import './guard' // guard permission control
|
||||
import './utils/filter' // global filter
|
||||
Vue.config.productionTip = false
|
||||
import Setting from './config/setting'
|
||||
import { Icon } from 'ant-design-vue'
|
||||
|
||||
Vue.prototype.$bus = EventBus
|
||||
import iconFont from '../public/iconfont/iconfont'
|
||||
|
||||
// mount axios Vue.$http and this.$http
|
||||
Vue.use(VueAxios)
|
||||
// 存在直接crash的风险 还未到
|
||||
const customIcon = Icon.createFromIconfontCN(iconFont)
|
||||
Vue.component('ops-icon', customIcon)
|
||||
var vue;
|
||||
|
||||
new Vue({
|
||||
router,
|
||||
store,
|
||||
i18n,
|
||||
created: bootstrap,
|
||||
render: h => h(App)
|
||||
}).$mount('#app')
|
||||
async function start() {
|
||||
const _vue = new Vue({
|
||||
router,
|
||||
store,
|
||||
created: bootstrap,
|
||||
render: h => h(App)
|
||||
}).$mount('#app')
|
||||
vue = _vue
|
||||
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
window.$app = vue
|
||||
window.$router = router
|
||||
window.$store = store
|
||||
window.$env = process.env
|
||||
}
|
||||
}
|
||||
|
||||
start()
|
||||
window.$setting = Setting
|
||||
|
||||
export default vue
|
||||
|
Reference in New Issue
Block a user