Having problems accessing prismic data in Nextjs

Hello, I'm using Next + Typescript + Slicemachine. I'm not using the App router. I found a weird behavior in my application. I can only access/render data from prismic if I use this "Is Client" check inside a UseEffect. That is to make sure there is a client side render. I started doing this because I wasn't being able to render my SliceZone without this strategy. Later I found the same is happening with all the other data (outside my slices). I haven't found any information about this on the web. I'm really tired and frustrated. The print shows my index.tsx (my homepage, pages/index.tsx).

If my post doesn't have enough info about this issue, please tell me, and I will try my best to provide more details.

Hi @contas,

Many users are experiencing problems with data caching in the App Router. We think this is a problem on the Next.js side, and we're looking into it. You can find more information here:

I'll let you know when we have a solution.

Sam

Hi @contas,

We've opened an issue on the Next.js GitHub repository. Feel free to upvote and subscribe for updates:

Sam

i am also facing the same issue.