From 4d8d98e8665c8b00b506f989938e00c8dace28d7 Mon Sep 17 00:00:00 2001 From: Drew Neil Date: Sun, 4 Jan 2026 23:07:46 +0000 Subject: [PATCH] Fix GitHub Pages deployment with correct path prefix Configures Eleventy to use the /qmk_userspace/ path prefix for GitHub Pages deployment since the site is hosted at nelstrom.github.io/qmk_userspace/ instead of the root domain. Changes: - Add pathPrefix: "/qmk_userspace/" to .eleventy.js config - Update all href and src attributes to use Eleventy's url filter - Navigation links: / becomes {{ '/' | url }} - CSS link: /public/css/theme.css becomes {{ '/public/css/theme.css' | url }} - SVG paths: Use url filter for SVG diagram references - Keymap links: Dynamically build paths with url filter This ensures all assets and links work correctly when deployed to GitHub Pages under a subdirectory path. --- website/.eleventy.js | 3 ++- website/src/_includes/layouts/base.njk | 4 ++-- website/src/index.njk | 2 +- website/src/keymaps.njk | 6 +++--- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/website/.eleventy.js b/website/.eleventy.js index 72628dae..67f919f7 100644 --- a/website/.eleventy.js +++ b/website/.eleventy.js @@ -64,6 +64,7 @@ module.exports = function(eleventyConfig) { }, templateFormats: ["njk", "md", "html"], htmlTemplateEngine: "njk", - markdownTemplateEngine: "njk" + markdownTemplateEngine: "njk", + pathPrefix: "/qmk_userspace/" }; }; diff --git a/website/src/_includes/layouts/base.njk b/website/src/_includes/layouts/base.njk index c664a7bf..4a7d3748 100644 --- a/website/src/_includes/layouts/base.njk +++ b/website/src/_includes/layouts/base.njk @@ -4,7 +4,7 @@ {{ title }} | QMK Keymap Documentation - +