How to add dark theme into your ReactJS or React Native app with Context and hooks

Photo by Diego Vicente on Unsplash

In this article, I’m going to cover the basic setup needed to add a theme support to your ReactJs or React Native app without using any third-party libraries. All the global state changes are going to be implemented through the usage of Context API and related hooks. No complex Redux or MobX implementation is required and the whole setup is quite…