J
J
justadumb2019-07-27 23:01:52
React
justadumb, 2019-07-27 23:01:52

Is it ok to use another HOC, with a Redux connection that holds ALL of the application's state?

I want to make one hock container for the entire redux state, pass it to the children, the components will read only what they need for themselves.
The question is - is it normal to pass a huge state in props? Or not worth it? Why?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Askhat Bikmetov, 2019-07-27
@justadumb

will only read what they need

Bad idea. Thus, the signature of the component will be determined not explicitly, but through the bodies of its functions. If a component needs some object, it (the component) must explicitly report this in the props.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question