feat: optimize some stuff
This commit is contained in:
@@ -4,7 +4,7 @@ import Logo from "./Logo.astro";
|
||||
import ToggleTheme from "@components/ThemeToggle.svelte";
|
||||
|
||||
function isActive(path: string) {
|
||||
return Astro.url.pathname === path;
|
||||
return Astro.url.pathname.startsWith(path);
|
||||
}
|
||||
|
||||
const t = useTranslations(Astro.url);
|
||||
|
||||
Reference in New Issue
Block a user