I’d pretty much settled on moving to Astro. I’d got things basically working. The site was decidedly lacking in features, but I could build it out slowly. It was fine.
But then I realised that several of the features I wanted - automatic navigation for static files, table of contents, light/dark mode - were built in to Starlight. And while I’d abandoned the idea of using Starlight because I’d hit some limitations, I’d learned a bit more about Astro since then, and Starlight is built on Astro. So maybe I should give it another look.
A documentation platform built on Astro. Not the obvious platform for what is, essentially, a personal blog. But I really want to write more ‘static’ stuff. Articles about photography. Guides and how-to articles, not just ‘what I did today’ blog posts. This post you’re reading now is a blog post, but I want my site to encourage me to write stuff that’s a bit less time-based, and hopefully, more useful in the longer term.
Starlight can have multiple collections of documents. Any new document added to a collection can automatically add itself to the sidebar for navigation. It has a table of contents in another sidebar, which gives readers an overview of longer documents, and lets them jump to the part they want.
Why I Abandoned It
I jumped around a lot of attempts when first starting this, so memory may be a little hazy, but I’m fairly sure I gave up on my attempts to make old posts from WordPress appear at their original URLs. Being able to do that, or at least redirect to them, was required. A few old posts still have some traction out there, and have been linked to, and I’m not willing to break that.
I’d tried using a ‘slug’ file to take over the URLs, which worked in Astro, but not in Starlight. I think it’s because Starlight actually does just that behind the scenes, hidden away in its modules, in a way that isn’t easy to override. But I’d missed something, I think because I didn’t know about it at the time. Adding the slugs to the frontmatter of the posts, just did what I wanted, super easily. The pages just take the URL given. Job done.
The other problem was that there was no blog, but a plugin has been made to do a bit of a basic half-assed blog function. It’s still being worked on, but it does the job well enough for now. Feeds would be nice, and many other ‘bloggy’ features would be nice too, but it adds a separate collection of dated posts. I think that’s enough for now.
Trying Starlight Again
So with that, I started chucking my content into Starlight. And it works well. It hasn’t taken long to get it to a pretty nice state; where with Astro, I’d barely made it usable at all, and it would probably take a lot more work to get what I wanted.
Writing, not Fiddling
That’s what it came down to. I think if I went with Astro, I’d have a fun new hobby of building my site, trying to add the features I wanted over the coming months. With Starlight, the important bits are already there, and other people are working on adding a lot of what’s missing. I can spend time writing actual articles for my site instead.