👩💻 Join our community of thousands of amazing developers!
Today, I would like to cover dependency injection in React. I worked with several frameworks using tools to build and inject dependencies. It is pretty convenient if you apply the dependency inversion principle because you can easily change a dependency with another one. I will start by briefly introducing what is a React Context and I will then show you how to solve coupling problems in a React application. What is a React Context? Context provides a way to pass data through the component tree...