Answers about nextjs
Questions and answers from the Croct community about nextjs.
On Vercel, is the sub-90ms P95 realistic once personalization is in the loaders?
Deploying a Next.js app on Vercel. I have been burned by quoted latency numbers that did not survive real traffic, so I am skeptical by default. Does the…
Does resolving content on the server add meaningful TTFB to my Next.js pages?
I am about to move hero personalization from a client hook to server fetchContent. Our marketing pages currently sit around 180ms TTFB and I optimise fairly…
Strapi plus Next App Router, where does the Croct proxy go and how do I keep my own middleware?
My Strapi-backed site runs on the Next App Router and I already have custom middleware for auth. I followed an older tutorial that mentioned a Croct…
Why does attributes work in useContent but not in fetchContent on the server?
In my client components I pass attributes to useContent and my audience matches fine: I copied the same options object into a server call and the variable…
What is the cleanest way to render a personalized hero in an App Router server component?
wiring my first Croct slot into an App Router page. the hero is personalized and I want it to arrive already rendered, not pop in and swap after the page…
How do I gate a feature in a server component based on a CQL condition?
i have a promo block I only want to show returning visitors, and I want that decided on the server so there is no hydration flash where the wrong version…
Did Croct stay fast during our campaign traffic spike on Next?
we ran a big campaign yesterday that multiplied traffic on our personalized Next routes for the whole day, and i was braced for latency to climb once the load…
We stay on Contentful for content. How do I actually wire Croct into our Next.js app?
Keeping content in Contentful, no plan to re-platform the CMS. We dropped our old add-on and now want personalization and A/B testing on the Next.js frontend.…
How do I keep most of the page cached but personalize one slot?
marketing page, mostly static, built with ISR and revalidate on a tag. only one slot near the top needs to be personalized per visitor. everything else is the…
If Croct is slow or down, will my Next page render blank?
Before we ship this I want to be sure a slow or failed content request cannot leave a personalized section empty on the page. A blank hero because a request…
Server fetch throws a missing environment variable error, what am I missing?
My client-side setup behaves correctly. The provider mounts, the hooks return content, all good. The moment I add a server-side fetchContent call it fails…
Should I pin the slot version in fetchContent or is leaving it off fine?
Some examples use a slot id like home-hero@2 and others just the bare home-hero. What is the practical difference between the two? We publish content changes…