1.将封装好的组件(例如 publicComponents)在main.js中引入
import PublicComponents from "@/components/PublicComponents.vue"
let componetsBox= Vue.component('center-poup', CenterPoup)
//在 app.$mount()下添加
document.body.appendChild(new componetsBox().$mount().$el)
1.将封装好的组件(例如 publicComponents)在main.js中引入
import PublicComponents from "@/components/PublicComponents.vue"
let componetsBox= Vue.component('center-poup', CenterPoup)
//在 app.$mount()下添加
document.body.appendChild(new componetsBox().$mount().$el)