From 559ee6a4a9975ea94cac09dfc9e9efb8723a524b Mon Sep 17 00:00:00 2001 From: Ronald Tse Date: Sun, 6 Sep 2026 23:00:07 +0200 Subject: [PATCH] fix: build flat page URLs to keep the pre-Astro URL space Astro's default directory format emits about/index.html, which makes every legacy URL 301 to a trailing slash and disagree with the canonical tags. --- astro.config.mjs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/astro.config.mjs b/astro.config.mjs index 5a17ba7..9318316 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -18,6 +18,8 @@ function yamlData() { export default defineConfig({ site: 'https://www.expresslang.org', output: 'static', + // Flat filenames (about.html) keep the pre-Astro URL space — no trailing-slash 301s + build: { format: 'file' }, integrations: [vue()], vite: { plugins: [tailwindcss(), yamlData()],