The solution presented in this article adds a loading progress bar to Next.js sites using a custom ‘useProgress’ hook and a ‘ProgressLink’ component, making page transitions smooth without needing router events. It keeps sites responsive and interactive during loads by utilizing React’s ‘startTransition’. The method is future-proof and improves the user experience.
Monday, April 8, 2024This tutorial teaches how to use Next.js Server Actions for manipulating data. Server Actions, combined with React Server Components (RSC) and the App Router, can be used to edit entities within the database without the need to convert Server Components to Client Components for database interactions.
Next.js 14.2 offers faster local development with Turbopack improvements, along with clearer error messages and improved overlay design. It also has less memory usage during builds.
Next.js needed a new bundler due to the limitations of Webpack in handling large-scale applications, particularly with the increasing use of component libraries and the rise of computationally heavy applications. The new bundler, Turbopack, aims to provide faster HMR and initial compile times, maintain compatibility with existing applications, and scale effectively for large codebases. It will also incorporate persistent caching and production optimizations.
Deploying Next.js applications on Cloudflare pages is not a seamless process due to a lack of documentation, inconsistencies with Next.js conventions, compatibility problems with a Vercel CLI change, issues with Set-Cookie headers, and challenges with logging and Node.js compatibility.
Partial Pre-Rendering (PPR) in Next.js combines the best of static site generation, server-side rendering, and client-side rendering. By pre-rendering static portions of a page at build time and streaming dynamic content at request time, PPR is able to have fast initial page loads, personalized content, and interactivity in a single HTTP request. This article goes into how PPR works.
- Clerk team explains building session management in Next.js without using any authentication library.
Session management is a concept that flies under the radar in most applications, but it has a crucial role to play: keeping users securely logged in when they use different tabs or devices. Because session management is often abstracted away by auth libraries, many developers are fuzzy about the details. In this blog post, the Clerk team details the step-by-step process of building session management in Next.js, without using any authentication library.