This post was originally posted on dev.to
If you are an Android or iOS developer who want to learn React Native then this blog post is for you. Here I’ll tell you how you can learn it easily. This is how I prepared to learn React Native.
Basically I didn’t wanted to learn from video courses. So I mainly focused on tutorials that provide built-in editors and blog posts.
Also learn about the different functions available for Arrays from MDN website. There are several helper functions available for many functionalities like creating new array from another array, merging two arrays, filtering items from array, etc. It will be very handy since it eliminates writing boilerplate code.
Once you understand them, start learning ReactJs. You can get started from the official website as it is well documented and has a tutorial to build an app. Use your ES6 features here to get used to it.
The main things you should have learnt after completing the tutorial are Lifecycle of a React Component, JSX syntax, and what are props and state.
React Native uses Flexbox layout style to render views in a much easier and responsive way. It’ll a bit difficult to understand the concepts of Flexbox, but once you understand it will be very easy to use. I recommend reading this guide to know all about it. You can keep it open in a separate browser tab so that you can go and refer it whenever you face any difficulties. You can learn by doing through online editors available like this and this.
If you clearly understand all the above concepts, then it’ll be very easy to learn React Native.
Also choose an editor of your choice to code. I personally prefer Visual Studio Code. It has some great features and a whole lot of extensions to make it easy to code.
Now you are ready to learn React Native. Go to their official website and go through their getting started guide to build a sample app. Read all the basics provided in the docs.
Once you get an idea of how to build an app, start doing a demo app to apply all the features you learnt. Avoid using any libraries at first. Try to use what you learnt so far to build a basic app or at least complete a few screens. Once you complete that then try some libraries.
While choosing libraries, always decide on the ones that are well maintained and recommended by the official docs.
Since an important function in mobile app is how to navigate between screens, it is important to know how it’s done in React Native. As of this writing, RN recommends to use libraries like ReactNavigation and React Native Navigation to use same code for both Android and iOS.
Go through their docs and apply the library in your demo app.
Finally learn how to build a Release version of your app.
After all the basics, learn some advanced libraries. For instance, state management libraries like Redux or MobX. They provide better ways to manage app states and better ways to test your app.
That’s it. If you came up to this stage, then you are ready to build a production ready app.
* * *