Showing posts from June, 2021

Newest feature of Next.js: Incremental Site Regeneration (ISR)

I am sure you are already aware of the difference between Static Site Generation (SSG) and Server Side Rendering (SSR) and their benefits respectively.  The key difference between the two is that SSG generates the HTML at build time, making it static, but allows for changes to UI using client-side scripting (JS) to make it dynamic whereas, SSR generates HTML on page request. The benefit of SSR is that it allows you to change HTML without requiring a build, which means you can continuously update the UI without requiring a build.  This key difference makes SSG fast and performant and ideal for brochure ware sites, blogs, developer documentation etc. and make SSR comparatively slow but ideal for portals and dynamic applications. Next.js does a great job of enabling both using React. Now some say SSG should be the default way forward but there are reasons why SSR becomes a preferred approach. However, with Next.js v9.5, a new feature was announced called Incremental Site Regeneration. Thi