import { Plugin } from "vue" import MyPluginComponent from "@/sql-builder/SqlBuilder.vue" const MyPlugin: Plugin = { install(Vue) { Vue.component("platon-sql-builder", MyPluginComponent) } } if ("Vue" in window && !MyPlugin._installed) { window.Vue.use(MyPlugin) } export default MyPlugin // const plugin = { // _installed: false, // install(Vue) { // Vue.component("platon-slq-builder", () => import("@/views/sql-builder/SqlBuilder.vue")) // this._installed = true // } // } // if ("Vue" in window && !plugin._installed) { // window.Vue.use(plugin) // } // export default plugin