Why I moved to NextJS?

November 15, 2023 (1y ago)

23 views

Hey, it's been some time since I posted here, in case you were wondering what I was doing, I have been trying to read this wonderful book called, Structure and Interpretation of Computer Programming. Coming to the title of this post, I chose to write this post, because I wanted to get back to writing, and the first thing I wanted to do, was improve the experience of this website.

I have recieved both compliments, and criticism regarding the user experience that this blog brings to my readers. Lately the experience had been crappy both for the readers, and for me when I tried optimizing this website for better response times. If you are new here, I used to use gatsby and netlify cms for writing posts here. I have now moved to nextjs due to the following reasons.

1. Building the site was slow

From a clean cache, it took from 4-8 minutes to build, which meant that regular deployments to netlify were starting to get taxing. It also meant that any debug tasks which required a production build were intolerably slow, and very frustrating.

2. Developer Experience

I used to have gatsby's older versions and many of the dependencies were outdated in my blog. It was okay-ish and things were managable when I first started out, but it grew into a mess very quicky when I started writing more around 8 months ago. Updating a minor fix in UI used to take hours due to dependency issues and backword incompability issues in production.

Nextjs appears to have a much larger developer community, and it also claims to be the most developer-friendly react framework for building production apps. So, this migration idea should be an excellent way for me to become acquainted.

3. Gatsby seems to dying...

Next starts a dev server within seconds.

The Gatsby team seems to be investing their energies only in pushing their infrastructure (Gatsby Cloud) which is honestly almost a requirement if deploying a Gatsby Website (without it you will have to rebuilt the entire website after a small CMS change and wait at least 3 mins).

Yeah, it's a great technology and implementation of React and GraphQL that got caught in a death spiral via monetization and VC money. No shade on the company for taking that path, it made sense at the time, but it's just not that useful of a tool in 2023.

That's it

In conclusion, the decision to migrate from Gatsby to NextJS was driven by a desire to enhance both the user experience of my blog and my own development experience. The slower build times, coupled with maintenance challenges in Gatsby, pushed me to explore alternatives. NextJS, with its superior build performance, robust developer community, and a focus on developer-friendly practices, emerged as the optimal choice for my needs.

Technology evolves, and so should our tools. While Gatsby served me well for a time, the move to NextJS represents a strategic decision to align with a framework that better meets the demands of modern web development in 2023. I look forward to leveraging the benefits of NextJS to provide an even more seamless and enjoyable experience for both myself and my readers.


Rick SanchezFavicon by Icons8

Design Template by Lee Robinson