I am new to redux and working on a MERN app. I need to use data from a collection "Assetmaster" in a few of the react components.
One option is fetching the data through axios, useEffect and render my table in the react component. But as I need to use this data in other components also i have to dispatch it to the Redux store using useDispatch(). In this case other components can use the data using useSelector().
However I need to know if it is possible to get the data directly in Redux Store centrally without fetching it in any of the components. And in such case do we need to use useEffect to ensure the data is fetched each time any changes in the collection is made to the database through any of the react component.