docs: Fix navbar issues. Keep stay when clicked other menu items from the sidebar.

This commit is contained in:
Arista Indrajaya 2024-03-06 08:31:14 +07:00
parent e9e69425ca
commit 7f6e4abb7f

View File

@ -32,7 +32,8 @@ export default function Layout(props) {
const location = useLocation();
const isAllowedPath = allowedPaths.includes(location.pathname);
const isAllowedPath = allowedPaths.some(path => location.pathname.startsWith(path));
return (
<LayoutProvider>
<PageMetadata title={title} description={description} />