Hacker News new | ask | show | jobs
Where to Put State? (twitter.com)
1 points by srachamim 2456 days ago
1 comments

Those programmes where I put state in one place dedicated to managing state (e.g. Redux) were much more easier to reason about then those where I put state everywhere, anywhere somewhere (Parent? Current component? Context provider? Apollo? Redux?)

Man, that should be that simple: Everything is from above.

Is it gonna change? Then it's a state. Put it in a state manager and pass it from top to bottom.

Every other solution is a workaround.