Fix sidebar on mobile (#703)

This commit is contained in:
saltrafael 2022-01-14 18:07:44 -03:00 committed by GitHub
parent a1a7ca321f
commit 031a3a2f0a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -80,7 +80,8 @@ function Page(props: Props) {
if (isOnFilePage || isMediumScreen) setSidebarOpen(false); if (isOnFilePage || isMediumScreen) setSidebarOpen(false);
// TODO: make sure setState callback for usePersistedState uses useCallback to it doesn't cause effect to re-run // TODO: make sure setState callback for usePersistedState uses useCallback to it doesn't cause effect to re-run
}, [isOnFilePage, isMediumScreen, setSidebarOpen]); // eslint-disable-next-line react-hooks/exhaustive-deps
}, [isOnFilePage, isMediumScreen]);
return ( return (
<> <>