Category "next.js"

.next folder size increases in Next react App

We have developed the nextjs react application, which is ready in production now. It leads to some storage issues. we inspect a lot and finally found .next fold

Ensuring sensitive code is run only server-side with NextJS, where can such code be ran from?

I'm learning NextJS and I'm trying to determine how to layout my project with a clean architecture that's also secure. However, I'm not sure about where to stor

Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './lib/parser' is not defined by "exports" in /usr/app/node_modules/postcss/package.json

Did a docker-compose up to build my project, but there's something wrong and I am getting this error: node:internal/errors:464 ErrorCaptureStackTrace(err);

How can I export a JSON object to Excel using Nextjs/React?

I have an endpoint that retrieves a json object like the following: "data": [ { "id": 1, "temaIndicador": "Indian", "codigo": "001", "observaciones": "Interacti

How can I use Bootstrap 5 with Next.js?

After installing bootstrap with npm install bootstrap I added the style to /pages/_app.js like so: import 'bootstrap/dist/css/bootstrap.css'; export default fun

Is it possible to make a join query with Prisma without a foreign key?

I've been struggling with this for a while but with no success. I have two tables that might have a relation but not necessarily. FIRST +----+-----------+------

Is it possible to make a join query with Prisma without a foreign key?

I've been struggling with this for a while but with no success. I have two tables that might have a relation but not necessarily. FIRST +----+-----------+------

Where to implement SWRs pagination for managing pagination in url?

I have been trying to solve the problem that this NextJS application does not have any pagination being handled on the backend so the idea being to pass it to q

Is it possible to run Mongoose inside next.js api?

I'm building a website for my sister so that she can sell her art. I am using Next.js to set everything up. The website renders the artwork by grabbing an array

Next-auth sign In working locally but not on vercel. Error- CLIENT_FETCH_ERROR

I've used next-auth with google signIn in my next application. I've set the environment variables as well as the auth file under api as import GoogleProvider fr

Next.js ISR pass additional data to getStaticProps from getStaticPaths

In SingleBlogPost.jsx i have: export async function getStaticPaths() { const res = await fetch("http://localhost:1337/api/posts"); let { data } = await res.

How to use Azure application insights with nextjs app

I want to use Azure app insight with nextjs but unable to do it , can anyoe help me with that?

NextJS - Too Many Open Files Error in Production

I'm facing an issue in my Production environment during peak traffic hours. Any help on identifying the source of this error would be really appreciated. Error

ESIDIR Error in NextJs, even if the code come from the official page

I need to learn Next.js for an interview, so I started to follow the tutorial published in Next.js official web page. It was all ok, until I arrived at this sec

Adding Google Ads Code in NextJS for Automatic Units

I'm working on a nextjs project and I have to implement the google AdSense code that is for automatic ads. So, my google ad code is just this: <script asyn

This error happened while generating the page. Any console logs will be displayed in the terminal window

1st time its show this error I want to make an API call to my API route using Axios. When I run my code the first time its shows that error but when I refresh

How to take benefit of Image component from Next.js and framer-motion svg animation

I have a Next.js project, where I am using framer-motion for some animations. I have the following code where using framer-motion I animated an svg: function Te

Next.JS and Mongoose models

I'm building a pretty simple next.js app for a client and for my life I cannot figure out why I keep getting Cannot overwrite User model once compiled. It seems

Does getStaticProps fetch data every time I get back same page?

I am using routes to get page ex. page/[id].js and show data for that id only. So will it refetch data every time I visit this page? ex. going to the next page

FormData with NextJS API

Background I am trying to create a simple CRUD application using NextJS along with react-redux, so what it does is that it saves peoples contacts.So when adding