Skip to content

Commit a4d6ba3

Browse files
authored
fix(type): fixed an issue where el could not accept a regular element type when list was not provided. (#208)
1 parent 5213d8d commit a4d6ba3

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/useDraggable.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -115,11 +115,7 @@ export function useDraggable<T>(
115115
options?: RefOrValue<UseDraggableOptions<T>>
116116
): UseDraggableReturn
117117
export function useDraggable<T>(
118-
el: Ref<HTMLElement | null | undefined>,
119-
options?: RefOrValue<UseDraggableOptions<T>>
120-
): UseDraggableReturn
121-
export function useDraggable<T>(
122-
el: null | undefined,
118+
el: RefOrElement<HTMLElement | null | undefined>,
123119
options?: RefOrValue<UseDraggableOptions<T>>
124120
): UseDraggableReturn
125121

0 commit comments

Comments
 (0)