Answer the question
In order to leave comments, you need to log in
How to properly render data from the store?
There is a property in the store, let it be obj, this is an object, there are a lot of objects in it, when you click on the button, a new object will be added to obj, and in the end you need all this to be rendered correctly, click on the button, and something on the screen there is a new one taken from store.obj
Answer the question
In order to leave comments, you need to log in
First you create a store and pass reducers to it. further in the root component you wrap the provider and pass it a store. Then, in the required component, map state and pass it to the component as a prop. and this component changes according to the store.
As an example:
https://codesandbox.io/embed/github/reactjs/redux/...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question