Since last week was Thanksgiving here in the States, I’ve had the idea of gratitude on my mind quite a bit lately. I’ve always treated gratitude as something “extra”. Like, yea, it’s great and all, but it’s not necessary . Gratitude is an example of “going above and beyond”, right? Well, right or…
Read Article →Like useState and useContext , useReducer is a new twist on a familiar concept. State reducers have been very popular within the React community for years. The popularity of the Redux library is a testament to this fact. Redux actually became so popular that it was almost seen as synonymous…
Read Article →Testing is a crucial weapon of any developer's arsenal. Testing ensures your code actually does what you coded it to do. Therefore, understanding how to write good tests is vital. Having said that, this is not an article on what testing is , nor is it intended to teach you how write tests…
Read Article →useEffect is the replacement for all of the lifecycle methods in class components - think componentDidMount , componentDidUnmount , etc. However, it's not just a replacement for lifecycle methods. useEffect can be used for more than that. We have to shift our thinking from useEffect is just…
Read Article →In my previous post I wrote about the Context API, prop drilling, and composition. We learned that sometimes state management problems can be solved simply by how we structure our components, not using Context. It's important to at least try using composition first. If it doesn't work, then you…
Read Article →The Context API, one may even call it a pattern as well, gives us a way to share data, or state, among components without having to pass the state as props. Context is not something that has always existed in React. In fact, it's relatively new. It helps solve the problem of prop drilling . For…
Read Article →