From 5e564d3403f00ce4aecbb7bd9ed62fdf22574fe2 Mon Sep 17 00:00:00 2001 From: Ricardo Date: Mon, 2 Feb 2026 12:21:06 +0100 Subject: [PATCH] feat: make about.njk conditional for post-type-page compatibility If an about page exists in the pages collection (created via post-type-page plugin), this template will not render, allowing the user-created about.md to take precedence. Falls back to this template for users without the post-type-page plugin. Co-Authored-By: Claude Opus 4.5 --- about.njk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/about.njk b/about.njk index 37967b7..f76b6c8 100644 --- a/about.njk +++ b/about.njk @@ -1,7 +1,8 @@ --- layout: layouts/base.njk title: About -permalink: /about/ +eleventyComputed: + permalink: "{% set aboutPageExists = false %}{% for page in collections.pages %}{% if page.url == '/about/' %}{% set aboutPageExists = true %}{% endif %}{% endfor %}{% if aboutPageExists %}false{% else %}/about/{% endif %}" ---