Astro Info
Astro v6.3.1
Vite v7.3.2
Node v24.13.1
System Linux (x64)
Package Manager npm
Output static
Adapter none
Integrations @astrojs/mdx (v5.0.4)
@astrojs/sitemap (v3.7.2)
Describe the Bug
When frontmatter have slug field then CollectionEntry.Id returns slug value. This can break code that relies on CollectionEntry.Id parsing.
Workaround. Set custom generateId:
generateId: ({ entry }) => entry.replace(/\.mdx?$/, "")
The doc says nothing about such behavior.
Astro Info
Describe the Bug
When frontmatter have
slugfield then CollectionEntry.Id returnsslugvalue. This can break code that relies on CollectionEntry.Id parsing.Workaround. Set custom generateId:
generateId: ({ entry }) => entry.replace(/\.mdx?$/, "")The doc says nothing about such behavior.