I think that GraphQL is not that different from REST but dramatically improves the developer experience of building and consuming APIs.

If you are like me when you come across a new technology there is one small moment of frustration but after you start reading the documentation and examples, you get more and more interested in it and want to start trying it even before you finished skimming the docs.

This is the case with me and GraphQL… once again.

In my previous job I had some communication with one of the ProductHunt iOS app’s developers. He told me about…

Do you know what is the difference between a class component and a function component in React?

In this practical guide I will try to explain how the component’s state is managed in both components after the second got on steroids!

Photo by Brook Anderson on Unsplash

Stateful and Stateless components

In the previous example, we mentioned the two types of components — the class-based components that can have internal state and the function component that are stateless, i.e. cannot have a state.

If you have any experience with React, you most certainly used the setState() method. Let’s review this simple class component:

It’s fairy simple… 🙃


Create a new file in your React Native project’s root dir with name react-native.config.jsand content:


Now, if you’re exporting for Android, go to: $PROJECT_ROOT/android/app/src/main/assets/fonts and paste your fonts.


Go back to your project’s root dir and execute this command in the terminal:
react-native link


Run the app with:
react-native run-android

And that is all! 🥳

This article was originally posted here: https://www.seishin.me/lets-add-custom-font-to-a-react-native-app/

In February I posted an article in my blog with example of how to switch React Native Paper themes dynamically via the recently introduced Context API.

Today, I will try to rewrite the example with the latest big thing in React world — React Hooks! I’m so excited about this addition since writing functional components are much better solution than the class-based way! With them is much more easier to code, test and maintain and after the hooks introduction — they’re on steroids with state management and handling lifecycle events! 🚀

So, lets dive in the revised example with hooks!

1. Lets create a file: Themes.js, containing our themes:

2. Create a file called AppContextProvider.js and write a function that will provide our AppContext Provider:

In this article I’ll try to explain in a simple way what are the React Hooks and why it’s good to use them when developing your React/React Native apps.

Since React 16.8.0, there is a new way of calling async code in a really elegant way as well as reuse logic between components much more easily.


  1. Gentle Introduction
  2. The useState() Hook: Practical Guide

Okay, but what is the problem?

If you’re not new to React, you will most probably know that there are two type of components — stateful and stateless. …

Atanas Dimitrov

Mobile Dev (Android/iOS Native & React Native) 🚀

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store