diff --git a/packages/hooks/src/useKeyPress/index.ts b/packages/hooks/src/useKeyPress/index.ts index abe4af3..4d836f3 100644 --- a/packages/hooks/src/useKeyPress/index.ts +++ b/packages/hooks/src/useKeyPress/index.ts @@ -1,5 +1,4 @@ import { ref } from 'vue' -// import { isFunction, isNumber, isString } from 'lodash' import { BasicTarget, getTargetElement } from '../utils/domTarget' import useDeepCompareEffectWithTarget from '../utils/useDeepCompareWithTarget' import { isNumber, isFunction, isString } from '../utils' diff --git a/packages/hooks/src/useRequest/plugins/useDebouncePlugin.ts b/packages/hooks/src/useRequest/plugins/useDebouncePlugin.ts index 7d3aae7..47bc2db 100644 --- a/packages/hooks/src/useRequest/plugins/useDebouncePlugin.ts +++ b/packages/hooks/src/useRequest/plugins/useDebouncePlugin.ts @@ -7,7 +7,7 @@ const useDebouncePlugin: UseRequestPlugin = ( fetchInstance, { debounceWait, debounceLeading, debounceTrailing, debounceMaxWait } ) => { - const debouncedRef = ref>(); + const debouncedRef = ref void) => void>>(); const options = computed(() => { const ret: DebounceSettings = {}; const debounceLeading_ = unref(debounceLeading) diff --git a/packages/hooks/src/useRequest/plugins/useThrottlePlugin.ts b/packages/hooks/src/useRequest/plugins/useThrottlePlugin.ts index 2ced2af..6c6a1a0 100644 --- a/packages/hooks/src/useRequest/plugins/useThrottlePlugin.ts +++ b/packages/hooks/src/useRequest/plugins/useThrottlePlugin.ts @@ -1,5 +1,5 @@ import { computed, unref, watchEffect } from 'vue' -import { DebouncedFunc, ThrottleSettings } from 'lodash' +import type { DebouncedFunc, ThrottleSettings } from 'lodash' import throttle from 'lodash/throttle' import { UseRequestPlugin } from '../types' diff --git a/packages/use-request/src/plugins/useThrottlePlugin.ts b/packages/use-request/src/plugins/useThrottlePlugin.ts index 2ced2af..6c6a1a0 100644 --- a/packages/use-request/src/plugins/useThrottlePlugin.ts +++ b/packages/use-request/src/plugins/useThrottlePlugin.ts @@ -1,5 +1,5 @@ import { computed, unref, watchEffect } from 'vue' -import { DebouncedFunc, ThrottleSettings } from 'lodash' +import type { DebouncedFunc, ThrottleSettings } from 'lodash' import throttle from 'lodash/throttle' import { UseRequestPlugin } from '../types'