diff options
Diffstat (limited to 'src/components/Header.astro')
| -rw-r--r-- | src/components/Header.astro | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/components/Header.astro b/src/components/Header.astro new file mode 100644 index 0000000..724150e --- /dev/null +++ b/src/components/Header.astro @@ -0,0 +1,29 @@ +--- +const navItems = [ + { linkText: 'Home', href: '/' }, + { linkText: 'Revalidation', href: '/revalidation' }, + { linkText: 'Image CDN', href: '/image-cdn' }, + { linkText: 'Edge Function', href: '/edge' }, + { linkText: 'Blobs', href: '/blobs' } +]; +--- + +<nav class="flex flex-wrap items-center gap-4 pt-6 pb-16 sm:pt-12 sm:pb-24"> + <a href="/"> + <img src="/netlify-logo.svg" alt="Netlify logo" /> + </a> + {!!navItems?.length && ( + <ul class="flex flex-wrap gap-x-4 gap-y-1"> + {navItems.map((item) => ( + <li> + <a + href={item.href} + class="inline-block px-1.5 py-1 transition hover:opacity-80 sm:px-3 sm:py-2" + > + {item.linkText} + </a> + </li> + ))} + </ul> + )} +</nav>
\ No newline at end of file |
