Skip to content

Commit

Permalink
[@mantine/hooks] Clear cleanupMap after ref assignment
Browse files Browse the repository at this point in the history
  • Loading branch information
elecdeer committed Dec 25, 2024
1 parent 8ed7594 commit 8bd5694
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/@mantine/hooks/src/use-merged-ref/use-merged-ref.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Ref, useCallback, type RefCallback, type RefObject } from 'react';
import { Ref, useCallback, type RefCallback } from 'react';

type PossibleRef<T> = Ref<T> | undefined;

Expand Down Expand Up @@ -33,6 +33,7 @@ export function mergeRefs<T>(...refs: PossibleRef<T>[]) {
assignRef(ref, null);
}
});
cleanupMap.clear();
};
}
};
Expand Down

0 comments on commit 8bd5694

Please sign in to comment.