Personal blog with Sanity CMS, SWR infinite pagination, and Bootstrap 4 styling

The Trianglify plugin and the Webflow blog were tools for the era they lived in — jQuery for distribution, visual editors for authoring. By 2020 I was writing React full-time and the pattern had shifted: headless CMS for content, Next.js for rendering, the JavaScript ecosystem for everything in between.
This was the first personal blog built on that stack. Next.js 9 was the right choice for the time — getServerSideProps meant content from Sanity arrived already rendered, not assembled by the client. Sanity provided the editor interface. The combination separated concerns cleanly: content authors worked in Sanity's studio, the Next.js layer handled how it appeared.
The listing page had a volume of posts that made pagination necessary. Two options: traditional page-based navigation (reload the page, new URL, new fetch) or client-side infinite scroll with SWR. I chose SWR.
The stale-while-revalidate cache strategy is the right call for a content listing: serve the cached version immediately, revalidate in the background, update the UI when fresh data arrives. The reader gets instant response; the data stays current. SWR's cursor-based pagination made infinite scroll straightforward without a custom hook or state management overhead.
That decision — SWR for data that can be stale briefly but not permanently — became a pattern I carried into later projects. It is the correct tool for public-facing content that updates on a human timescale rather than a real-time one.
The blog accumulated 75 commits over three years. Not every commit was a feature — many were content updates, small style adjustments, dependency bumps. That history is the record of a product being used and maintained rather than shipped and abandoned.
The Sanity CMS evaluation that happened through this project informed the later decision to use Sanity again — and the decision to eventually replace it. A structured schema works well for content with predictable shape. Where Sanity fell short was the editing experience: the studio is designed for structured input, not long-form writing. That gap is what led to the brother's blog iterations with Hygraph and eventually headless WordPress. The Next.js blog established the pattern; the subsequent projects refined what the editing surface actually needed to be.
Did this resonate?