Add linter on CI

This commit is contained in:
Charles Bochet
2023-04-20 11:44:47 +02:00
parent 5469d27911
commit b8d089395f
21 changed files with 55 additions and 24 deletions

View File

@ -1,9 +1,9 @@
const onOutsideClick = jest.fn();
import { useRef } from 'react';
import TableHeader from '../../components/table/table-header/TableHeader';
import { render, fireEvent } from '@testing-library/react';
import { useOutsideAlerter } from '../useOutsideAlerter';
import { act } from 'react-dom/test-utils';
const onOutsideClick = jest.fn();
function TestComponent() {
const buttonRef = useRef(null);

View File

@ -17,5 +17,5 @@ export function useOutsideAlerter(
return () => {
document.removeEventListener('mousedown', handleClickOutside);
};
}, [ref]);
}, [ref, callback]);
}