1234567891011121314151617181920212223242526272829 |
- import Vue from 'vue'
- import App from './App.vue'
- import router from './router'
- import singleSpaVue from 'single-spa-vue'
- Vue.config.productionTip = false
- const vueOptions = {
- el: '#single-spa-app',
- router,
- render: (h) => h(App)
- }
- let vueLifecycles = {}
- if (process.env.VUE_APP_ALONE) {
- delete vueOptions.el
- new Vue(vueOptions).$mount('#app')
- } else {
- vueLifecycles = singleSpaVue({
- Vue,
- appOptions: vueOptions
- })
- }
- export const bootstrap = vueLifecycles.bootstrap
- export const mount = vueLifecycles.mount
- export const unmount = vueLifecycles.unmount
- export default vueLifecycles
|