chore(ci): eslint + prettier → biome (#325)

This commit is contained in:
Sam Potts
2026-01-23 11:33:04 +00:00
committed by GitHub
parent 93d8b95b2d
commit bf76dfa593
204 changed files with 1172 additions and 4443 deletions
@@ -1,6 +1,5 @@
import type { MutableRefObject, RefObject } from 'react';
import { render } from '@testing-library/react';
import type { MutableRefObject, RefObject } from 'react';
import { useRef } from 'react';
@@ -32,7 +32,7 @@ function setRef<T>(ref: PossibleRef<T>, value: T): (() => void) | void | undefin
*/
export function composeRefs<T>(...refs: PossibleRef<T>[]): RefCallback<T> {
return (node): (() => void) | void => {
const cleanups = refs.map(ref => setRef(ref, node));
const cleanups = refs.map((ref) => setRef(ref, node));
return () => {
for (let i = 0; i < cleanups.length; i++) {
@@ -59,6 +59,5 @@ export function composeRefs<T>(...refs: PossibleRef<T>[]): RefCallback<T> {
* ```
*/
export function useComposedRefs<T>(...refs: PossibleRef<T>[]): RefCallback<T> {
// eslint-disable-next-line react-hooks/exhaustive-deps
return useCallback(composeRefs(...refs), refs);
return useCallback(composeRefs(...refs), [...refs]);
}