Reputation: 1131
As i am a beginner on redux and i searched on the web about it. I got the answer as a state container. Even we can maintain the state of the element in the jquery just like the below code
if ($('.foobar').hasClass('active')) {
doSomething();
}
Can anyone tell me what it is actually?
Upvotes: 0
Views: 277
Reputation: 160271
Redux is a state container.
You can maintain state in the DOM, but this is awful if you have an alternative. Why?
Being able to have a single, solid mechanism for mutating state is a huge win across the board. Having known mechanisms for interacting with that state, recording that state, tracking that state, etc. is a huge win.
Upvotes: 2