UNPKG

w-vue-middle

Version:

统一公共服务组件

57 lines (46 loc) 1.14 kB
/* * @Author: Jason Liu * @Date: 2020-11-13 09:09:50 * @Desc: */ import Vue from 'vue' import App from './App.vue' import { winMiddle } from "../index"; import { microRegister } from '../microService'; import router from "./router"; //主路由文件引入 require('w-vue-basis') const vuedragzone = require("vue-drag-zone"); Vue.use(vuedragzone); JSON.copyData = function (info = {}) { let result = info; try { result = JSON.parse(JSON.stringify(info)) } catch (error) { } return result; } const subApp = new winMiddle(Vue, {}) //关闭菜单权限 $storage.set("SYS_Authority_Disable", "false"); /** * @Author: Jason Liu * @description: 微前端服务主持 */ let micro = new microRegister({ verified: true, el: '#app', router, render: (h) => h(App) }); export async function bootstrap(props) { micro.bootstrap(props); } export async function mount(props) { micro.mount(props); } export async function unmount(props) { micro.unmount(props); } export async function update(props) { micro.update(props); }