feat: added site map

This commit is contained in:
Leyla Becker 2026-02-11 15:51:26 -06:00
parent 7682677cf6
commit a7676d06b6
9 changed files with 62 additions and 21 deletions

15
sitemap.njk Normal file
View file

@ -0,0 +1,15 @@
---
permalink: /sitemap.xml
eleventyExcludeFromCollections: true
---
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{%- for page in collections.all %}
{%- if page.url and page.url != "/sitemap.xml" and not page.data.excludeFromSitemap %}
<url>
<loc>{{ site.url }}{{ page.url }}</loc>
<lastmod>{{ (page.data.updatedAt or page.data.createdAt or page.date) | isoDate }}</lastmod>
</url>
{%- endif %}
{%- endfor %}
</urlset>