1 Star 0 Fork 546

alun/Vue3可视化表单_低代码表单_工作流表单_表单设计器_Element表单_CRUD表单

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
install.js 1.68 KB
一键复制 编辑 原始数据 按行查看 历史
vdpAdmin 提交于 2022-01-01 19:15 . 初步完成库文件打包配置。
import axios from 'axios'
import VFormDesigner from '@/components/form-designer/index.vue'
import VFormRender from '@/components/form-render/index.vue'
import Draggable from '@/../lib/vuedraggable/dist/vuedraggable.umd.js'
import SvgIcon from '@/components/svg-icon' //svg组件
import 'virtual:svg-icons-register'
import ContainerWidgets from '@/components/form-designer/form-widget/container-widget/index'
import ContainerItems from '@/components/form-render/container-item/index'
import { addDirective } from '@/utils/directive'
import { installI18n } from '@/utils/i18n'
import { loadExtension } from '@/extension/extension-loader'
VFormDesigner.install = function (app) {
addDirective(app)
installI18n(app)
loadExtension(app)
app.use(ContainerWidgets)
app.use(ContainerItems)
app.component('draggable', Draggable)
app.component('svg-icon', SvgIcon)
app.component(VFormDesigner.name, VFormDesigner)
}
VFormRender.install = function (app) {
installI18n(app)
loadExtension(app)
app.use(ContainerItems)
app.component('svg-icon', SvgIcon)
app.component(VFormRender.name, VFormRender)
}
const components = [
VFormDesigner,
VFormRender
]
const install = (app) => {
addDirective(app)
installI18n(app)
loadExtension(app)
app.use(ContainerWidgets)
app.use(ContainerItems)
app.component('draggable', Draggable)
app.component('svg-icon', SvgIcon)
components.forEach(component => {
app.component(component.name, component)
})
}
// if (typeof window !== 'undefined' && window.Vue) { /* script方式引入时主动调用install方法!! */
// window.axios = axios
// install(window.Vue);
// }
export default {
install,
VFormDesigner,
VFormRender
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/alun999999/variant-form3-vite.git
git@gitee.com:alun999999/variant-form3-vite.git
alun999999
variant-form3-vite
Vue3可视化表单_低代码表单_工作流表单_表单设计器_Element表单_CRUD表单
master

搜索帮助