Follow what's done in astro-blog
Posted on 18th May 2026 at 15:40 by NickP
Implementation
-
copy src/pages/select-posts.astro from astro-blog. Make one change of ‘blog’ to ‘posts’ for the collection and four of ‘blog’ to ‘post’ in url slug sections.
-
npm install fuse.js
-
Change path in get_post_lines() in src/utils/post_helpers.js to make links like /posts/author/xxxx rather than /blog/author/xxxx. Similarly for /category/, /tag and /yyyy/mm.
-
Add src/pages/posts/author/[author].astro, src/pages/posts/category/[category].astro, src/pages/posts/tag/[tag].astro and src/pages/posts/[year]/[month].astro
-
Add menu item