diff --git a/src/hooks/component/useFormItem.ts b/src/hooks/component/useFormItem.ts index cee415e88..1296bb14c 100644 --- a/src/hooks/component/useFormItem.ts +++ b/src/hooks/component/useFormItem.ts @@ -1,14 +1,5 @@ import type { UnwrapRef, Ref, WritableComputedRef, DeepReadonly } from 'vue'; -import { - reactive, - readonly, - computed, - getCurrentInstance, - watchEffect, - unref, - nextTick, - toRaw, -} from 'vue'; +import { reactive, readonly, computed, getCurrentInstance, watchEffect, unref, toRaw } from 'vue'; import { isEqual } from 'lodash-es'; @@ -50,7 +41,7 @@ export function useRuleFormItem( if (isEqual(value, defaultState.value)) return; innerState.value = value as T[keyof T]; - nextTick(() => { + setTimeout(() => { emit?.(changeEvent, value, ...(toRaw(unref(emitData)) || [])); }); },