Answers about app-router
Questions and answers from the Croct community about app-router.
Can I call fetchContent inside generateMetadata to personalize the page title?
We personalize the hero on our category pages and I would like the meta title and description to match the variant the visitor sees, instead of a generic…
Best pattern for mixing fetchContent in Server Components with useContent in client islands?
I lead a team at an agency and we are writing down conventions for Croct in App Router projects before we roll it out across several client builds. The SDK…
Streaming SSR with a Suspense boundary around each personalized section, good idea or overkill?
News site, aggressive perf targets. Home page has a static shell plus three personalized sections (top stories rail, mid-page promo, newsletter block), each a…
Adding fetchContent turned my statically generated pages dynamic, is that expected?
We run a marketplace with heavy ISR usage, thousands of prerendered pages. I added fetchContent from @croct/plug-next/server to one product landing page and…
Parallel routes with @hero and @sidebar slots, can each one call fetchContent independently?
Building a dashboard layout with Next.js parallel routes and the naming is melting my brain a bit. Next calls @hero and @sidebar "slots", Croct calls its…
How do I pass the next-intl locale to fetchContent so slots come back localized?
Hi everyone! We run a travel marketplace with es, en and fr routes using next-intl. The slot content from fetchContent always comes back in default language,…
next build fails with Dynamic server usage on a page that calls fetchContent
Added fetchContent to a route that also uses generateStaticParams and the build now fails during prerendering: The route is one of our statically generated…
Sorry if this is dumb but where do I pass appId to CroctProvider in Next.js?
Sorry if this is a dumb question, I am a junior dev at my first job and I have been stuck on this for longer than I want to admit. I followed the React docs…