Tag Archives: React Native

How to expose swift class to react native class?

By | September 10, 2024

There will be situations where you have to expose your Swift class to React Native. To do this, you need to use some Obj-C Macros available in React Native. To use these Obj-C Macros, you need a new Obj-C file: You have to import RCTBridgeModule, so that you can use the Macros to bridge the native… Read More »

Flutter vs. React Native: Unraveling the Performance Battle

By | June 25, 2023

Introduction: When it comes to developing cross-platform mobile applications, Flutter and React Native have emerged as the two dominant frameworks. As developers seek to create high-performing apps, it’s crucial to understand the performance capabilities of each framework. In this article, we will delve into the performance aspects of Flutter and React Native, examining their strengths… Read More »

Is Javascript Multithreaded? How it handles asynchronous actions?

By | December 13, 2018

Javascript is a single threaded application. That means you cannot run more than one script at one time to modify DOM or something. But there are something called “Worker Threads” that spans separate threads outside your application that can do complex tasks which is linked by a Callback method. What is a Web Worker? When… Read More »

RNFirebase core module was not found natively on ios – Fix

By | October 28, 2018

This issue happens in react-native-firebase for a various reasons. First thing you have to do is check Firebase/Core is in your pods. Try Cleaning and rebuilding your project. Click on the target you are running in xcode and check the frameworks section in ‘General’ Tab -> Check you have linked libFirebase.a there. If not click… Read More »

How to extend styles in React-Native?

By | August 10, 2018

We will create different styles to style different components, correct? And most of them will have duplicate elements, correct? What are the disadvantages of this problem? You will clutter your file with duplicate lines of code. It will increase the file size and increase the application size. Not very efficient way of coding. Limited reusability.… Read More »

How to create a custom native ImageView/View in Android or iOS for ReactNative?

By | July 11, 2018

Many times we need custom components from native. Here is a simple example on how to create a custom imageview in Android for react native. First we will start with the Android Version Android Create a class that extends SimpleViewManager. Write a setSrc method which accepts the source url from React Native. Implement ‘createViewInstance’ method… Read More »

How to Monitor network requests in a React Native/React Application?

By | August 9, 2018

So how do we normally monitor all the operations in a react native applications. All the networks, redux state etc. So you will need a plugin/package for this. Its called Reactotron. Here is the github page for Reactotron. What is Reactotron? A macOS, Windows, and Linux app for inspecting your React JS and React Native… Read More »

Awesome React Native Image Caching Libraries

By | July 4, 2018

Image Loading and caching had been a little bit pain in react native. In-fact react native didn’t had native support for caching. But after the recent release, there is now support for caching in iOS only. Still not for Android. You can read more about this from here https://facebook.github.io/react-native/docs/images.html#cache-control-ios-only Now these are the variety of… Read More »

What are promises in React Native, How is it different from Callbacks?

By | May 9, 2018

Basically saying both are same. But there are some differences. Lets see what are some of the advantages of Promises. Promises are just a cleaner way for running asynchronous callbacks. Promises also has error catching mechanism which are not in callbacks. Promises are an abstraction for cleaner and better functional code. What are callbacks? Callback… Read More »

React Native Module Bridge Example

By | July 12, 2018

The document demonstrates the steps to create react native module bridge in Android and iOS. Below are the steps for creating a native bridge in Android. ANDROID Open the Android Studio with the corresponding project from your react native project. Step 1 : Create the Java class that extends ReactPackage. (eg: AndroidModulePackage.java). Implement the interface… Read More »