fix: eslint warnings (#278)
This commit is contained in:
@@ -12,7 +12,7 @@ import eslintPluginNext from '@next/eslint-plugin-next';
|
||||
export default tseslint.config(
|
||||
{
|
||||
name: 'unittcms/ignore-globally',
|
||||
ignores: ['**/node_modules/', '**/.next/', '**/docs/'],
|
||||
ignores: ['**/node_modules/', '**/.next/', '**/docs/', '**/coverage/'],
|
||||
},
|
||||
{
|
||||
name: 'unittcms/load-plugins',
|
||||
|
||||
@@ -95,8 +95,8 @@ export default function TestCaseTable({
|
||||
const [showFilter, setShowFilter] = useState(false);
|
||||
const [localQueryTerm, setLocalQueryTerm] = useState(queryTerm);
|
||||
|
||||
const debouncedQuery = useDebounce((value: string) => {
|
||||
onQueryChange(value);
|
||||
const debouncedQuery = useDebounce((value: unknown) => {
|
||||
onQueryChange(value as string);
|
||||
}, 500);
|
||||
|
||||
useEffect(() => {
|
||||
@@ -179,8 +179,8 @@ export default function TestCaseTable({
|
||||
default:
|
||||
return cellValue as string;
|
||||
}
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
},
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
[localQueryTerm]
|
||||
);
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { useRef, useCallback, useEffect } from 'react';
|
||||
|
||||
export default function useDebounce<T extends (...args: any[]) => void>(
|
||||
export default function useDebounce<T extends (...args: unknown[]) => void>(
|
||||
fn: T,
|
||||
delay: number
|
||||
): (...args: Parameters<T>) => void {
|
||||
|
||||
Reference in New Issue
Block a user