From 383a77567360a69fb6962d21e8862709f1c90433 Mon Sep 17 00:00:00 2001 From: Eric Eldredge Date: Mon, 4 Mar 2019 13:24:17 -0500 Subject: [PATCH] fix(docz-theme-default): toggle active links on location change --- .../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 }