Different Authentication strategies i n Next Js

Modern web applications commonly use several authentication strategies: OAuth/OpenID Connect (OIDC): Enable third-party access without sharing user credentials. Ideal for social media logins and Single Sign-On (SSO) solutions. They add an identity layer with OpenID Connect. Credentials-based login (Email + Password): A standard choice for web applications, where users log in with an email and… Continue reading Different Authentication strategies i n Next Js

Resolving Server side cache issues in Nextjs

Next.js has a built-in Data Cache that persists the result of data fetches across incoming server requests and deployments.  By default, data requests that use fetch are cached. We can use the cache and next.revalidate options of fetch to configure the caching behavior. The Data Cache is persistent across incoming requests and deployments unless you… Continue reading Resolving Server side cache issues in Nextjs

Time-based Revalidation in Next Js

Revalidating Data Revalidation is the process of purging the Data Cache and re-fetching the latest data. This is useful when your data changes and you want to ensure you show the latest information. Cached data can be revalidated in two ways: Time-based revalidation: Automatically revalidate data after a certain amount of time has passed. This… Continue reading Time-based Revalidation in Next Js

Route handlers in Nextjs

In Nextjs web development, Route Handlers play a crucial role in creating custom request handlers for specific routes using Web Request and Response APIs. What are Route Handlers? Route Handlers are tools that enable developers to customize how their web application responds to different types of requests for specific routes. These handlers are particularly useful… Continue reading Route handlers in Nextjs

Strategies for Reducing the Cache in Next Js API calling(Data fetching)

import { NextResponse } from “next/server”;    export const GET = async (req, res) => {  // Add cache-busting query string or HTTP headers as needed  const url = new URL(req.url);  url.searchParams.set(‘t’, Date.now()); // Optional: Cache busting    try {  const response = await fetch(url, {  headers: {  ‘Cache-Control’: ‘max-age=3600, must-revalidate’, // Example header  }, … Continue reading Strategies for Reducing the Cache in Next Js API calling(Data fetching)

Image compression libraries in Next.js

Next.js itself does not provide specific image compression libraries, as it’s more focused on server-side rendering, routing, and other aspects of web development. However, you can use third-party libraries within your Next.js project for image compression. Here are a few popular JavaScript libraries for image compression: image-size: A simple library to get the dimensions of… Continue reading Image compression libraries in Next.js

How to convert PNG/JPEG image to WebP format in Figma editor

WebP offers superior compression, resulting in smaller file sizes for faster webpage loading and reduced bandwidth usage compared to PNG and JPEG. Additionally, WebP supports both lossless and lossy compression, providing flexibility in balancing image quality and file size. In order to convert PNG/JPEG images to WebP format, perform the following steps. Sign in to… Continue reading How to convert PNG/JPEG image to WebP format in Figma editor

How to send get and post request in API using Node JS & using Postman

This article covers the topic of How to send get and post request in API using Node JS & using Postman 1. Install Axios: First, we need to install the Axios library. we can do this by running the given command in our Node.js project directory: npm install axios 2. Sending GET and POST Requests… Continue reading How to send get and post request in API using Node JS & using Postman

Published
Categorized as Next.Js

NextUI

NextUI is a UI library for React that helps us to build beautiful and accessible user interfaces.This is created on top of Tailwind CSS and React Aria. NextUI’s primary goal is to streamline the development process, offering a beautiful and adaptable system design for an enhanced user experience. How is NextUI different from TailwindCSS? TailwindCSS: Tailwind CSS is… Continue reading NextUI