Category "next.js"

testing fastapi response to next.js with fetch, promise stuck in pending?

my fetch is stuck in pending when I query a fastapi endpoint in local dev. followed this blog and a few others - https://damaris-goebel.medium.com/promise-pendi

Next.JS Image `layout='fill'` is broken

When using the Next.js image component, the docs claim that: "When fill, the image will stretch both width and height to the dimensions of the parent element, u

Using Nextjs Image component with different image sizes

I am trying to use the Next.js Image component with images that all have unique sizes. Their example states the image will stretch to the parent div width and h

Listen to route change with next.js to use with matomo/piwik

I'm trying to listen to route changes on a next.js app, in order to log navigation to matomo (aka piwik). According to next.js' documentation, I have to do some

how to hide nextjs api routes from being directly accessible through url?

Is there any way to make next.js API routes response data hidden when accessing it through URL? I want to hide the routes because there is some data I don't wan

NextJS: How to correctly add firebase analytics to NextJS app

I have a react/nextjs app and I have firebase.js as follow: import firebase from 'firebase/app' import 'firebase/auth' import 'firebase/analytics' import 'fireb

Target Active Link when the route is active in Next.js

How to target the active Link in Next.js like they way we do it in React-Router-4? Meaning, give the active link a class when its route is active?

Use custom theme - next.js, less, ant design

my goal is to modify default theme in antdesign but I cant achieve it. I even move from sass to less but still something won't work. I tried probably everything

NextJS - getServerSideProps - Error 400 - Bad Request

I'm getting a problem using fetch within the NEXT JS with the getServerSideProps function. As I'm starting with this framework, I'm probably not doing it well.

Next.js Authentication with JWT

I am moving a project from React to Next.js and was wondering if the same authentication process is okay. Basically, the user enters their username and password

Swiper grid module is not working in Next.js app

For two days, I've been really struggling to run a functional Swiper Grid option with my Next.js app. I've tried many stackoverflow solutions and tried differen

VS Code Scatters Next JS Files [duplicate]

I am learning NextJS right now but I can't seem to proceed, as anytime I make a change and hit CTRL + S The codes become scattered. See screen

Why should I use the next-js library in a react-native project

In the react-js project, I understand the benefit of having every page render on the server and not having to download all the pages when only one page is neede

Node engine version problem when deploying to vercel

So I had a nextjs project deployed to vercel, and today I committed a minor change that was deleting some console log statements and it wouldn't deploy anymore.

First Load JS shared by all is rather heavy in next.js

I have a project on Next.js framework and the problem is that First Load JS shared by all pages is rather heavy. I want to know what possible aspects I can tak

How to create a new user along with their profile images in Sanity?

Hi I am a beginner to Sanity and I am working on a personal project. All I want to know is how do I add a user along with his profile Image selected as a file f

How to create a new user along with their profile images in Sanity?

Hi I am a beginner to Sanity and I am working on a personal project. All I want to know is how do I add a user along with his profile Image selected as a file f

'Component' cannot be used as a JSX component. Nextjs

This is how _app.tsx looks: function MyApp({ Component, pageProps }: AppProps) { return <Component {...pageProps} /> } and I am getting this error whil

NextJs CORS issue

I have a Next.js app hosted on Vercel at www.example.com, which needs to communicate with a backend .NET Core Web API hosted on a different server at api.exampl

How do I include my credentials in getServerSideProps in Nextjs? [duplicate]

In the async function getServerSideProps I need to make a fetch from the back-end where I include my credentials to instantiate a session. I h