@coral apex my understanding is that trailingSlash: 'always' forces the URLs to have a trailing slash, doesn't add it - this is what is happening when I test it (below).
Check my code below, any sidebar link gives now a 404:
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import starlightBlog from 'starlight-blog';
import sitemap from '@astrojs/sitemap';
import tailwind from "@astrojs/tailwind";
export default defineConfig({
site: 'https://docs.getaiblogarticles.com',
trailingSlash: 'always', // Ensure all URLs end with a trailing slash
integrations: [
sitemap(),
starlightBlog({
title: 'Blog',
customCss: ['./src/styles/tailwind.css'],
authors: {
ric: {
name: 'AI Blog Articles',
title: 'Founder',
picture: '/logo.webp',
url: 'https://getaiblogarticles.com',
},
},
}),
starlight({
title: 'AI Blog Articles',
customCss: ['./src/styles/tailwind.css'],
description: 'Documentation for AI Blog Articles.',
logo: {
src: '/src/assets/logo.webp',
alt: 'AI Blog Articles',
},
head: [
{
tag: 'script',
attrs: {
src: 'https://www.googletagmanager.com/ns.html?id=GTM-5LTSJ89R',
},
},
{
tag: 'script',
content: `
(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});
var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';
j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;
f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-5LTSJ89R');
`,
},
],
// continue the rest
});