fix: use Link instead of a elements for optimization (thx nextjs)

This commit is contained in:
theoleuthardt 2025-02-13 01:09:37 +01:00
parent aa40c16a21
commit e11c705d3d

View file

@ -1,6 +1,7 @@
import React from "react";
import Image from "next/image";
import LOGO from "../assets/werkzeugkasten.svg";
import Link from "next/link";
interface NavProps {
className?: string;
@ -17,21 +18,21 @@ const Navbar = (props: NavProps) => {
</div>
<div className="flex flex-auto justify-center">
{props.renderHomeLink ? (
<a
<Link
href="/"
className="justify-center text-2xl hover:underline hover:transition-underline hover:duration-300 hover:text-blue-400"
>
home
</a>
</Link>
) : null}
</div>
<div className="flex flex-1 justify-end">
<a
<Link
href="https://github.com/theoleuthardt/werkzeugkiste"
className="items-end mr-3 text-2xl hover:underline hover:transition-underline hover:duration-300 hover:text-blue-400"
>
github
</a>
</Link>
</div>
</nav>
</div>