I took some time off as I was busy traveling but I'm back and so is our weekly newsletter! I went to Brussels for a conference. You can check out the snap here and Italy for vacation. It was a blast and a well needed break.
This week, I wanted to share more about the announcement of Next.js 14.
NextJS 14 has finally arrived!
It's that exciting time of the year where we will dive into all the fascinating changes NextJS 14 brings to our development workflow. The good news is, there are no new APIs, but there are quite a few fresh features and enhancements that will make building NextJS applications even more comfortable.
If you prefer to watch a video instead covering all the changes then check out my Youtube channel! 🎥
The noteworthy updates include changes in Turbopack, Server Actions, partial pre-rendering, and exciting news about a new NextJS course.
First off, let's talk about Turbopack. Originating from previous Next JS releases, Turbopack is a Rust compiler that has improved tremendously over time. All efforts have been made to stabilize Turbopack to ensure it delivers the best features of NextJS and provide a speedy development environment.
Through stringent testing (500,000 integration tests for Next dev are now passing with Turbopack), NextJS 14 has proven to deliver a whopping 53.3% faster local server setup and 94.7% faster code 🤯 updates at fast refresh, further promising a more efficient NextJS application building process.
NextJS 14 introduces us to the concept of Server Actions. Before, developers had to manually create different API endpoints, which often involved repeating a lot of code. But now, Server Actions allow you to create async functions within a component, making it possible to execute specific functions in a form for creating and updating data. Server Actions and Server Components, while similar, serve different purposes.
These new enhancements to Server Actions mean you can now handle actions like form submission directly inside your components. Performance-wise, Server Actions improve efficiency since mutation, data re-rendering, and redirection can now happen in one network round trip, and it also helps to better compose our application code.
Moving on to partial pre-rendering, this feature allows you to create a
Suspense boundary that shows parts of the page while server data is still being retrieved. Built on react suspense, this will help in keeping your user engaged while the rest of the content is loading. However, bear in mind that this feature is still under development and does not introduce any new APIs as yet, so there's no action required from developers for the time being.
If you're considering upgrading to NextJS 14 from Next 13 or an earlier version, please check out the 'breaking changes' section in the Next JS 14 documentation. This will outline what changes are necessary to ensure your Next 14 application is stable.
And that, folks, is your detailed guide to all the shiny new features and enhancements in NextJS 14! While it might not introduce any new APIs, it gifts us with stable Server Actions, which will undoubtedly bring about exciting changes in our development workflow.
Moving forward, my focus is to create more educational content on my Youtube channel so 🎥 subscribe if you haven't already just so you don't miss out!
And that's a wrap!!