Category "next.js"

Problem finding string atached to json file when translating (i18n)

I have successfully translated many of the pages on my website project but now I have moved to translate specific components that were created and it is not wor

how to deploy custom github branch on vercel

Is there a way to select a custom branch to deploy ? I do not seem to be able to select a branch and it takes the default main branch thanks in advance

Scroll to the last item of a mapped array

I have a Message component that displays all the messages(incoming and outgoing) in one thread. I would like the last message/a newly typed message/incoming mes

Warning: Function components cannot be given refs

I'm using Next.js latest version for making my blog website, don't know why show me error, when I'm trying to make my form then show me error like this: Warning

passing props as classNames in next.js

I am trying to have the header of each of my app's pages change color based on the current page. How I am trying to achieve this: <Header className="headerBi

Node JS Using AND or OR operator - Fetching data

Good Day! I need help on the below issue: Goal: is to filter data depending on the department content. What I'm trying to do is to fetch data from MongoDB based

Tailwind height transition not working on h-min, h-fit, h-max, and h-auto

So I like to make transition whenever the element change it's height. It works on h-10, h-20, etc. But it doesnt work on h-min, h-max, h-auto. ‎‎‎&l

Fill parent container and reduce image resolution with next/image

I'm trying to fill a fixed-size container with an image. layout="fill" works like a charm, but even though container is only 125x125, the original image gets do

"Websocket connection failed" when proxying requests to Next.js app via Apache server

Since upgrading to Next.js 12 I'm getting the following error in the console when I run my Next.js app: WebSocket connection to 'wss://mysite.local/_next/webpa

Using Remark and Rehype plugins with MDX in Next.js (with @next/mdx)

I was trying to use Github Flavored Markdown using @next/mdx but I can't seem to figure out how to use plugins with the code. Here is what I did: (I am followi

NextJS scroll into view of specific component upon button OnClick that exists on a different js file

I'm using NextJS and I have my components on different js files that come together under one js file on my "pages" folder (index.js). What I want to be able to

Adding inline stylesheets in HEAD on Next.js blog

I have a blog (http://minid.net) in Jekyll that I want to migrate to Next.js. My blog doesn't use an external file for styles. I embedded all the styles in the

Is it possible to generate static pages in nextjs when using redux-saga?

Warning: You have opted-out of Automatic Static Optimization due to getInitialProps in pages/_app. This does not opt-out pages with getStaticProps I tried dif

Dockerize NextJS Application with Prisma

I have created a NextJS application, to connect to the database I use Prisma. When I start the application on my computer everything works. Unfortunately, I get

next js dynamic route redirect to home page on refresh

I have a dynamic route in my project and its not ssr. When I refresh the page, it redirects to the home page, but in the other pages the refresh works as inten

Revalidate key in Next.js

As you know, we can update SSG page via revalidate key in getStaticProps() and user at firstly see latest content and after refresh page twice can see updated c

Next-Auth getSession is returning null in my development environment

I'm using the following code in one of my pages: export async function getServerSideProps(context) { const session = await getSession(context) return {

Next.js - router.push without scrolling to the top

I am using router from next by importing useRouter from next/router. I am trying to find a solution which will not scroll to the top of the page when I change t

ID is gone when I refresh a NextJS Dynamic Route page

I am trying to get dynamic routing working in order to display and retrieve the right information using the id from the url. This works when I visit the page, b

Next.js: How to get static assets from within getStaticProps

I am using Netlify CMS. I want to import all the slides for a carousel into my component. I made a collection called slider and added a few slides. That created