Home > Net >  Using react context for a small part of application
Using react context for a small part of application

Time:04-01

I've build a react project that has become quite huge now. I want to incorporate context for a step form so that I can escape the prop drilling process. Can I use it for that specific form or I will have to wrap the whole app with the context.provider function. Can I simply wrap that form with it and it'll do the job?

CodePudding user response:

i think that you can use for a specific component. However, i share you this official doc about React Context

CodePudding user response:

I think you should think in the future and wrap the whole app with it maybe your app become much bigger than it's now and need its values in other places in the app .. but you can use it for a specific component.

  • Related