From 1274b97bc39f995c8caba22e66d300de08cceb2e Mon Sep 17 00:00:00 2001 From: Eric Eldredge Date: Mon, 11 Mar 2019 21:48:07 -0400 Subject: [PATCH] fix(docz-theme-default): toggle active links on location change (#666) --- .../src/components/shared/Sidebar/SmallLink.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/docz-theme-default/src/components/shared/Sidebar/SmallLink.tsx b/core/docz-theme-default/src/components/shared/Sidebar/SmallLink.tsx index b0fc499cc..8ba490b91 100644 --- a/core/docz-theme-default/src/components/shared/Sidebar/SmallLink.tsx +++ b/core/docz-theme-default/src/components/shared/Sidebar/SmallLink.tsx @@ -66,7 +66,7 @@ export const SmallLink: SFC = ({ useEffect(() => { const currentHash = location.hash && location.hash.slice(1, Infinity) setActive(Boolean(slug === currentHash)) - }, []) + }, [location]) return }