From 29b35d6363b08dba5f4c6a196a19f0cef91b5d2c Mon Sep 17 00:00:00 2001 From: Satindar Dhillon Date: Mon, 3 Oct 2022 08:31:50 -0700 Subject: [PATCH] declare recentSearches as unknown array to avoid type error --- packages/web/components/templates/library/LibrarySearchBar.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/web/components/templates/library/LibrarySearchBar.tsx b/packages/web/components/templates/library/LibrarySearchBar.tsx index a0f243dd2..fb3a499dc 100644 --- a/packages/web/components/templates/library/LibrarySearchBar.tsx +++ b/packages/web/components/templates/library/LibrarySearchBar.tsx @@ -36,7 +36,7 @@ export type LibrarySearchBarProps = { } export function LibrarySearchBar(props: LibrarySearchBarProps): JSX.Element { - const [recentSearches, setRecentSearches] = useState(Array<[]>()) + const [recentSearches, setRecentSearches] = useState(Array()) useEffect(() => { setRecentSearches(Object.values(localStorage))