I have an application in Next.Js where I have a dashboard that I want to populate with data from other pages. My problem is that I cannot find a good way to save variables and then pass them to the dashboard if the other pages have not been loaded yet. For instance I want my dashboard to show the total number of entries I have in my table on my tables page. I can get that information to populate by using zustand and context provider wrappers but I can only achieve this after I have visited the tables page and the data populates.
I have tried using zustand stores and context providers to wrap my application in and they only work once the client side component containing the data has been rendered.
Cody Slivinski is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.