Category "next.js"

The default export is not a React Component in page: "/" NextJS

Not sure why the error is coming up, heres my index.js and App.js (the default export). I have used export default in the app.js. index.js: import "./index.cs

Is Next.js app an SPA or single page application?

Plain React apps are called SPA because they have only one html page which is the index.html. But that is not the case for next.js. So can we call a next.js app

Why do I get a 401 unauthorized error when logging in?

I am using the NextAuth.js credentials provider for the log in procedure. When logging in I am catching the errors in a try-catch block and set the error state

Using baseUrl in jsconfig.json is not working with Next.js

jsconfigerror is an example repository showing the jsconfig is not working. I have the following set inside my jsconig.json file: { "compilerOptions": { "

How to change the default screen background color of all the pages in React JS(Next JS) using tailwind CSS

I am trying to change the default screen background colour of all the pages of the web application. Technologies I used: React JS Next JS Tailwind CSS I want to

CORS issue fetching data with WPGraphQL and Next.JS

I have created a Next.js app using Wordpress as a CMS and WPGraphQL to fetch data. I have created apollo-client the following way: uri: process.env.NEXT_PUBLI

Poor next.js image component quality on Google Chrome

I am developing website using next.js framework. I have some problems with Image component in Google Chrome. It loading with poor quality. But when you download

getSession next-auth returns null

I am learning NextAuth, and I am just trying to get my current session in an API. Looks pretty easy from the documentation, but it keeps giving me null. If I us

How to remove in NextJS/React white spaces and non integer charcters when copy pasting a 2fa code inside a texfield input

I have a login that requires a 2FA authentication which is sent by email to the user. The code is long 6 digits. When a user copy-paste the code that appears as

Invalid suspense option usage in next/dynamic

I have a loader component and I want it to appear while my page is rendering. According to the docs, when using suspense my code should look like this const Dyn

Using fonts in chakra UI in Next js

My application is built using NextJs and uses Chakra UI. I have installed Google Fonts by following this chakra Google fonts npm install @fontsource/open-sans @

How to fix NextJS webpack error: You may need an appropriate loader to handle this file type, currently no loaders are configured

I generated NextJS project using TypeScript template and I want to add my Storybook to the project. Storybook is written in TypeScript. When I'm adding Storyboo

Why Is My Image out of sync with my Text?

I'm attempting to select a random slide from slides on page load, and display it in a hero section of a website. But, the Image keeps getting out of sync with t

NextJS deployed to AWS Amplify with ISR - build takes too long

By default, while deploying the NextJS app to AWS Amplify, it uses 7GB RAM. When I build my app on EC2 instance with 2GB RAM (1vCPU), building app takes less th

How do I get all documents in a Cloud Firestore collection using Version 9 of the Modular Web SDK?

I am trying to get all documents in a collection using version 9 of the Web SDK. But I am getting this error: "TypeError: querySnapshot.map is not a function"

Next.js error "Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'scrollTo')"

While making a portfolio website with Next.js, this is some sort of scrolling error that I'm getting from .next folder in my project folder. Whenever I'm trying

How can I import WebAssembly rust to NextJS?

Im using nextjs, I'm using an: import { greet } from "backend"; This is the package.json dependencies: "dependencies": { "backend": "file:../backend/pkg", "nex

Argument of type (key: string, id: string, pagination: number) => Promise<void> is not assignable to parameter of type Boolean

Not sure what is the matter here, but I am trying to follow this documentation: https://swr.vercel.app/ with this setup of my own: import React, { useEffect } f

How do i set two images in in same line at hexo blog?

I just build a blog for myself, build up by hexo and next. Today i have known how to set one picture by this : ![image description](img's url) But by this way

How to access route parameter inside getServerSideProps in Next.js?

I want to query my Supabase table using the ID in the slug e.g. localhost:3000/book/1 then show information about that book on the page in Next.js. Table book/