23 lines
530 B
Plaintext
23 lines
530 B
Plaintext
---
|
|
import Navlink from "./Navlink.astro";
|
|
const links = [
|
|
{
|
|
display: "Home",
|
|
href: "/"
|
|
}, {
|
|
display: "Blog",
|
|
href: "/blog"
|
|
}, {
|
|
display: "About",
|
|
href: "/about"
|
|
}, {
|
|
display: "Contact",
|
|
href: "/contact"
|
|
}
|
|
];
|
|
---
|
|
<nav class="w-full flex justify-center">
|
|
<div class="justify-around w-full md:w-[767px] flex">
|
|
{ links.map((item) => (<Navlink href={item.href}, display={item.display}, isActive={ (Astro.url.pathname.replace(Astro.currentLocale + "/", "").slice(0,-1) || "/") == item.href}/>)) }
|
|
</div>
|
|
</nav> |