Please note that this is just a simple walkthrough how to use redux. You might not need to do some steps below because soya next automatically handle it. However, I am still explaining them just to give you a basic knowledge how to use redux.
Redux can be viewed as 'temporary/in Memory database' to store your variable. It can be accessed anywhere from react component as long as the component connected to redux.
Like many other 'database', there are 2 usage in redux
- Retrieving value
It can be performed by using store.getState()
(You won't call this function manually if using soya-next)
- Manipulating the value in 'database'