mirror of
https://github.com/imdap/ruoyi-plus-vben5.git
synced 2026-05-07 18:51:46 +08:00
feat: 插件新增依赖注入功能
This commit is contained in:
@@ -2,6 +2,7 @@ import { createApp, watchEffect } from 'vue';
|
||||
|
||||
import { registerAccessDirective } from '@vben/access';
|
||||
import { registerLoadingDirective } from '@vben/common-ui';
|
||||
import { providePluginsOptions } from '@vben/plugins';
|
||||
import { preferences } from '@vben/preferences';
|
||||
import { initStores } from '@vben/stores';
|
||||
import '@vben/styles';
|
||||
@@ -13,7 +14,7 @@ import { $t, setupI18n } from '#/locales';
|
||||
import { router } from '#/router';
|
||||
|
||||
import { initComponentAdapter } from './adapter/component';
|
||||
import { initSetupVbenForm } from './adapter/form';
|
||||
import { initSetupVbenForm, useVbenForm } from './adapter/form';
|
||||
import App from './app.vue';
|
||||
import { initTimezone } from './timezone-init';
|
||||
|
||||
@@ -24,6 +25,11 @@ async function bootstrap(namespace: string) {
|
||||
// 初始化表单组件
|
||||
await initSetupVbenForm();
|
||||
|
||||
// 注入插件全局配置
|
||||
providePluginsOptions({
|
||||
form: { useVbenForm },
|
||||
});
|
||||
|
||||
// 设置弹窗的默认配置
|
||||
// setDefaultModalProps({
|
||||
// fullscreenButton: false,
|
||||
|
||||
Reference in New Issue
Block a user