From 062b09928664459e13c45a9549dd2176556d3af7 Mon Sep 17 00:00:00 2001 From: Jeffrey Aven Date: Tue, 15 Sep 2026 17:36:08 +1000 Subject: [PATCH] website: keep the Docusaurus default URL emission so trailing-slash URLs resolve The shared docusaurus-config sets trailingSlash: false, which makes Docusaurus emit .html; GitHub Pages then returns 404 for the same URL with a trailing slash. Dropping the setting restores /index.html, which is served for both forms. Co-Authored-By: Claude Fable 5.1 --- website/docusaurus.config.js | 78 +++++++++++++++++++----------------- 1 file changed, 42 insertions(+), 36 deletions(-) diff --git a/website/docusaurus.config.js b/website/docusaurus.config.js index 2dacbcf..6fa329c 100644 --- a/website/docusaurus.config.js +++ b/website/docusaurus.config.js @@ -1,36 +1,42 @@ -import {themes as prismThemes} from 'prism-react-renderer'; -import { createConfig } from './.shared-config/index.js'; -import { providerName, providerTitle } from './provider.js'; - -const config = createConfig({ - providerName, - providerTitle, - prismThemes, - overrides: { - future: { - v4: true, - faster: true, - }, - }, -}); - -// This provider's website lives at website/ within the canonical -// stackql-registry/stackql-provider-snowflake repo, so the "Edit this page" links -// point at that subdirectory (the shared config default omits the website/ path). -config.projectName = 'stackql-provider-snowflake'; -config.presets[0][1].docs.editUrl = - 'https://github.com/stackql-registry/stackql-provider-snowflake/edit/stackql-provider/website/'; - -// Use the locally vendored registry-branded logos (STACKQL>> | REGISTRY) instead -// of the shared config's hotlinked main-site wordmark - self-contained assets, no -// cross-origin fetch. global.css swaps in the -mobile variants below 996px. -const registryLogo = { - alt: 'StackQL', - href: '/', - src: 'img/stackql-registry-logo.svg', - srcDark: 'img/stackql-registry-logo-white.svg', -}; -config.themeConfig.navbar.logo = { ...registryLogo }; -config.themeConfig.footer.logo = { ...registryLogo }; - -export default config; +import {themes as prismThemes} from 'prism-react-renderer'; +import { createConfig } from './.shared-config/index.js'; +import { providerName, providerTitle } from './provider.js'; + +const config = createConfig({ + providerName, + providerTitle, + prismThemes, + overrides: { + future: { + v4: true, + faster: true, + }, + }, +}); + +// This provider's website lives at website/ within the canonical +// stackql-registry/stackql-provider-snowflake repo, so the "Edit this page" links +// point at that subdirectory (the shared config default omits the website/ path). +config.projectName = 'stackql-provider-snowflake'; +config.presets[0][1].docs.editUrl = + 'https://github.com/stackql-registry/stackql-provider-snowflake/edit/stackql-provider/website/'; + +// Use the locally vendored registry-branded logos (STACKQL>> | REGISTRY) instead +// of the shared config's hotlinked main-site wordmark - self-contained assets, no +// cross-origin fetch. global.css swaps in the -mobile variants below 996px. +const registryLogo = { + alt: 'StackQL', + href: '/', + src: 'img/stackql-registry-logo.svg', + srcDark: 'img/stackql-registry-logo-white.svg', +}; +config.themeConfig.navbar.logo = { ...registryLogo }; +config.themeConfig.footer.logo = { ...registryLogo }; + +// URL form. Keep the Docusaurus default (pages emitted as /index.html) +// regardless of the shared config's trailingSlash setting, so GitHub Pages +// serves both /services/x/y and /services/x/y/. A trailingSlash: false site +// emits .html instead, which returns 404 for the trailing-slash URL. +delete config.trailingSlash; + +export default config;