Our great sponsors
-
SurveyJS
Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.
So if you're alluding to "prop-drilling" (the unpleasant practice of passing data from a root component into deeper and deeper component context), then what you need is React's Context API. Here's an article which explains the problem and implements the solution. It's worth noting that the base Context API is a bit cumbersome on it's own, so I would recommend a CQRS state management library like Jotai. Just be sure to to add the special configuration step for use with Next.
React is built and intended to be used as ~Facebook's~ Meta's Flux architecture.
Related posts
- jotai-wrapper, a super tiny and simple utility library
- Jotai – Primitive and flexible state management for React
- Is there a state management library, similar to Redux or Zustand, that automatically generates setters for the state you define?
- Do i HAVE to use redux at this point?
- Why You Don't Need Signals in React