Next.js Discord

Discord Forum

[AppRouter+SSR] Which composition pattern should I use to prevent duplicate data in html & scripts?

Unanswered
Highlander posted this in #help-forum
Open in Discord
HighlanderOP
I am building a custom frontend for a CMS/blog. I fetch the data in an async function getData in [slug]/page.tsx and render it in the template. But what I see is that the data is present in the HTML (SSR) but also in self.__next_f.push , I have no intention of ever wanting hydration on content like this and want to reduce my HTML size and javascript footprint as much as possible. Is there a way to achieve this?

1 Reply