mirror of
https://github.com/zadam/trilium.git
synced 2025-11-06 05:15:59 +01:00
19 lines
300 B
TypeScript
19 lines
300 B
TypeScript
|
|
import { useLocation } from 'preact-iso';
|
||
|
|
|
||
|
|
export function Header() {
|
||
|
|
const { url } = useLocation();
|
||
|
|
|
||
|
|
return (
|
||
|
|
<header>
|
||
|
|
<nav>
|
||
|
|
<a href="/" class={url == '/' && 'active'}>
|
||
|
|
Home
|
||
|
|
</a>
|
||
|
|
<a href="/404" class={url == '/404' && 'active'}>
|
||
|
|
404
|
||
|
|
</a>
|
||
|
|
</nav>
|
||
|
|
</header>
|
||
|
|
);
|
||
|
|
}
|