treecounter-app icon indicating copy to clipboard operation
treecounter-app copied to clipboard

Implement context api to prevent props passing hell

Open mahmed0715 opened this issue 5 years ago • 0 comments

Describe the feature you'd like to see included in Plant-for-the-Planet App. Currently we use redux to share state, thats awsome, problem is for a component tree we needed to pass a props/function/action from top to very bottom on the tree, that causes sometimes missing props in somewhere in the middle. I think we can avoid this kind of passing props hell by using context api on UPDATED REACT(0.6+)

What are the use cases for this feature? We will use redux as is, but in addition we can use context api just to avoid these kind of issue.

Background: Today I had an issue like this, thus thought of implementing some kind of upgrade to this process..

Open discussion is required, I hope everyone commenting please check what context api can do for us.

mahmed0715 avatar Nov 09 '19 12:11 mahmed0715