Showing posts with label React Native. Show all posts
Showing posts with label React Native. Show all posts

Monday, December 28, 2020

React Native Vector Icons

React Native Vector Icons is the best react native libraries to get icons. Here you can see the list of a lot of icons. You can use this for buttons, logos, and nav/tab bars. This is easily customizable. It has 3K+ icons.



Please review below git URL for more information 
(https://github.com/oblador/react-native-vector-icons) -





You can install this with the help of below command -
npm install --save react-native-vector-icons

Now please follow the instructions mentioned on below URL -
https://github.com/oblador/react-native-vector-icons#installation


How to apply - After successfully installation please follow the below steps -

Import below line -
import Icon from 'react-native-vector-icons/Ionicons';


Add icons on your view -
<Icon name="ios-person" size={20} color="#0BB4E4" />

here "ios-person" is the icon name.


Sharing some icons and their names which you can also find on below URL -
https://oblador.github.io/react-native-vector-icons/

stepforward, stepbackward, forward, banckward, caretright, caretleft, 
caretdown, caretup, rightcircle, leftcircle, upcircle, downcircle, 
rightcircleo, leftcircleo, upcircleo, downcircleo, verticleleft, 
verticleright, back, retweet, retweet, shrink, arrowsalt, doubleright,
doubleleft, arrowdown, arrowup, arrowright, arrowleft, down, up, right, 
left, minussquareo, minuscircle, minuscircleo, minus, pluscircleo, 
pluscircle, plus, infocirlce, infocirlceo, info, exclamation, 
exclamationcircle, exclamationcircleo, closecircle, closecircleo, 
checkcircle, checkcircleo, check, close, customerservice, creditcard, 
codesquareo, book, barschart, bars, question, questioncircle, 
questioncircleo, pause, pausecircle, pausecircleo, clockcircle, 
clockcircleo, swap, swapleft, swapright, plussquareo, frown, menufold, 
mail, link, areachart, linechart, home, laptop, star, staro, filter, 
meho, meh, shoppingcart, save, user, videocamera, totop, team, sharealt, 
setting, picture, phone, paperclip, notification, menuunfold, inbox, 
lock, qrcode, tags, tagso, cloudo, cloud, cloudupload, clouddownload, 
clouddownloado, clouduploado, enviroment, enviromento, eye, eyeo, 
camera, camerao, windows, export2, export, circledowno, circledown, hdd, 
ie, delete, enter, pushpino, pushpin, heart, hearto, smile-circle, 
smileo, frowno, calculator, chrome, github, iconfontdesktop, 
caretcircleoup, upload, download, piechart, lock1, unlock, windowso, 
dotchart, barchart, codesquare, plussquare, minussquare, closesquare, 
closesquareo, checksquare, checksquareo, fastbackward, fastforward, 
upsquare, downsquare, leftsquare, rightsquare, rightsquareo, 
leftsquareo, down-square-o, up-square-o, play, playcircleo, tag, tago, 
addfile, folder1, file1, switcher, addfolder, folderopen, search1, 
ellipsis1, calendar, filetext1, copy1, jpgfile1, pdffile1, exclefile1, 
pptfile1, unknowfile1, wordfile1, dingding, dingding-o, mobile1, 
tablet1, bells, disconnect, database, barcode, hourglass, key, flag, 
layout, printer, USB, skin, tool, car, addusergroup, carryout, 
deleteuser, deleteusergroup, man, isv, gift, idcard, medicinebox, 
redenvelopes, rest, Safety, wallet, woman, adduser, bank, Trophy, 
loading1, loading2, like2, dislike2, like1, dislike1, bulb1, rocket1, 
select1, apple1, apple-o, android1, android, aliwangwang-o1, 
aliwangwang, pay-circle1, pay-circle-o1, poweroff, trademark, find, 
copyright, sound, earth, wifi, sync, login, logout, reload1, message1, 
shake, API, appstore-o, appstore1, scan1, exception1, contacts, 
solution1, fork, edit, form, warning, table, profile, dashboard, 
indent-left, indent-right, menu-unfold, menu-fold, antdesign, 
alipay-square, codepen-circle, google, amazon, codepen, facebook-square, 
dropbox, googleplus, linkedin-square, medium-monogram, gitlab, 
medium-wordmark, QQ, skype, taobao-square, alipay-circle, youtube, 
wechat, twitter, weibo, HTML, taobao-circle, weibo-circle, weibo-square, 
CodeSandbox, aliyun, zhihu, behance, dribbble, dribbble-square, 
behance-square, file-markdown, instagram, yuque, slack, slack-square

Saturday, December 26, 2020

Best React Native Libraries and Component

 1. NativeBase - This provides great UI components for React Native and Vue Native apps. This also supports platform specific design. This is a fully open source. It provides some build-in paid/free themes which are available on its market place. 

NativeBase


2. Teaset - This is a UI library to React Native apps, it gives us 20+ pure JS(ES6) components, focusing on content display and action control. You can find more details on Github.

Teaset


3. Material Kit React Native - This provides free React Native Apps templates. This provides a large number of components and cards. This has a lot of components to build a great UI of your app. It provides pixel perfect screens. You can view the documentation on this link - https://demos.creative-tim.com/material-kit-react-native/docs/?_ga=2.234190430.1994806609.1608998238-98775155.1608998238#/. 

Material Kit React Native


4. React Native Elements - This is easy to use and supports Expo too. We can also easily customize it's components. Some components names are below -

Avatar, Badge, BottomSheet, Button, ButtonGroup, Card, CheckBox, Divider, Header, HTML style headings, Icon, Image, Input, ListItem, Overlay, Pricing, Rating, SearchBar, Slider, Social Icons / Social Icon Buttons, Tile, Tooltip

React Native Elements


5. Lottie for React Native - This is a good library to add animations into the Apps. 

Lottie for React Native


Tuesday, March 19, 2019

No toolchains found in the NDK toolchains folder for ABI with prefix: mipsel-linux-android


This error comes due to NDK version mismatch, To resolve this error you have to download an older version of NDK and need to remap NDK path. Then you can build the project successfully. To do this please follow the below steps -

1. First, you need to open the NDK downloader page. You can open by using below URL -
https://developer.android.com/ndk/downloads/

2. Now at the bottom of this page, you can see "older versions of the NDK" and click on "NDK Archives" tag to see all older versions.



3. Agree with the Terms from this page by clicking on "I agree to the terms" button. After this, you can see all older versions of NDk.



4. Download your NDK older version from this list. In my case, it was "Android NDK, Revision 14b".



5. Open Android NDK location directory. You can check location from File -> Project Structure -> SDK location. Check below image for more information -



6. Now, Extract file which you have downloaded and move that folder in toolchains folder - (Or you can delete toolchain folder and past our recent downloaded toolchain on this location)



7. After this, you need to rebuild the project. 



This will resolve your issue. In some case, you can also try below solution -

Open Android Studio and go to File -> Project Structure -> SDK location, uncheck NDK If you do not need this, and then restart android studio. This will resolve your issue.


Please post a comment if you are still having an issue in this. I will try to resolve that issue.

Sunday, March 10, 2019

Undefined symbols for architecture x86_64


Hello All,

I am getting below error when I try to run the project in Xcode -


Undefined symbols for architecture x86_64:

  "_OBJC_CLASS_$_SKStoreProductViewController", referenced from:

      objc-class-ref in CDVAppRate.o

  "_SKStoreProductParameterITunesItemIdentifier", referenced from:

      ___29-[CDVAppRate launchAppStore:]_block_invoke in CDVAppRate.o

ld: symbol(s) not found for architecture x86_64

clang: error: linker command failed with exit code 1 (use -v to see invocation)



I have found the solution for this error. The solution is very simple, You need to add the StoreKit framework. To add this follow below steps -


1. Clicking on your project in the upper left of the left pane and select project from TARGETS -



2. In the middle pane you can see the "Build Phases" section, Now click on the Build Phases tab.

3. After this under "Link Binary With Libraries", click on the plus button.



4. Now search for "StoreKit" and find the StoreKit from the list and press Add button.



Now run the project again and the project will get run successfully. This works for me if you are still facing any issue please post your error in the comment section. I will try to resolve this issue.

Note - In my case this issue I faced in ionic / Cordova projects. But this is a common issue related to Xcode.   

Thursday, February 7, 2019

The sandbox is not in sync with the Podfile.lock in ionic


In my case, I was building an ionic project. This error comes when I try to run the project in iSO. I spend much time to resolve this issue, Some say we can run pod update OR pod install command to resolve this issue. But noting work in my case. Finally, I found the solution for this. This is very simple. Just follow the below steps to resolve the issue -    

1. First Quit your Xcode.
2. Now move in iOS platform folder. (i.e, Project Dir/platforms/ios)
3. Delete Pods folder from here.
4. Delete Podfile.lock from here.
5. Now open ios platform in the terminal and run "pod install" command in terminal. Make sure to run this command without admin (without sudo).
6. Now open your project in Xcode. Note - Open project via .xcworkspace file.

Now build and run the project, If that does not work follow below more steps - 

7. In Xcode, From navigation go to root node and from the Xcode on the right choose 'Build Settings' option.  Check more information in below image -




8. Now scroll down and there should be following entries - PODS_PODFILE_DIR_PATH and PODS_ROOT. If this available please correct the entry and if not available please add the entry by using below details - 


8.1 Click on the plus (+) icon to add the entry and select "Add user-defined settings". Check below image -




8.2 Add "PODS_PODFILE_DIR_PATH" and for both Debug and Release add "${SRCROOT}/." entry.
8.3 Now again add "PODS_ROOT" and for both Debug and Release add "${SRCROOT}/Pods" entry.

After adding the above details it will look like this -





Now try to build your project. It will build successfully. If still, you are facing any issue please post your error in the comment section. I will try to resolve this issue.

Sunday, December 16, 2018

Failed to find 'ANDROID_HOME' environment variable



I am getting below error when I am trying to run project -

> cordova build android
Android Studio project detected
(node:15997) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Failed to find 'ANDROID_HOME' environment variable. Try setting it manually.
Failed to find 'android' command in your 'PATH'. Try update your 'PATH' to include path to valid SDK directory.


To resolve this issue please run below commands in the terminal -

export ANDROID_HOME="/Users/chetandeshmukh/Library/Android/sdk"
export PATH="$ANDROID_HOME/platform-tools:$ANDROID_HOME/tools:$PATH"


How to find the Android SDK path?

First open android studio, Then click on SDK manager. For more info please check below image -



Now select Appearance & Behavior -> System Settings -> Android SDK



 Now copy your SDK location with the help of the above steps and update in command.


This process will set the Android Home path in your system.


Now try once again to run your project. This process will resolve your problem. If you still facing any issue please add your error in the comment section. We will resolve this. 

Tuesday, November 27, 2018

Could not find play-services-tasks-license.aar (com.google.android.gms:play-services-tasks-license:11.8.0)



Could not find play-services-tasks-license.aar (com.google.android.gms:play-services-tasks-license:11.8.0).
Searched in the following locations:
    https://jcenter.bintray.com/com/google/android/gms/play-services-tasks-license/11.8.0/play-services-tasks-license-11.8.0.aar


Please follow below steps to solve this issue:-


Go to build.gradel 



and replace this -

buildscript {
    repositories {
        mavenCentral()
        jcenter()
    }
}

with this -

buildscript {
    repositories {
        google()
        mavenCentral()
        jcenter()
    }
}


And replace this - 

allprojects {
    repositories {
        mavenCentral();
        jcenter()
    }
}


With this -

allprojects {
    repositories {
        google()
        mavenCentral();
        jcenter()
    }
}



Now - Click on “Sync Now”



If you again face this issue - 

A problem occurred evaluating root project 'android'. > Could not find method google() for arguments [] on repository container of type org.gradle.api.internal.artifacts.dsl.DefaultRepositoryHandler.


To resolve this issue add this line in your gradel file -

dependencies {
        classpath 'com.android.tools.build:gradle:3.0.1'
    }


If you are having this issue in react native app. Please use this below lines in your gradel file -


buildscript {
    repositories {
        jcenter()
        google()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.0.1'
    }
}
allprojects {
    repositories {
        mavenLocal()
        jcenter()
        maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url "$rootDir/../node_modules/react-native/android"
        }
        google()
    }
}




Make sure to sync your project after doing all this. This will resolve your issue.

Tuesday, October 2, 2018

How to generate APNS certificate for iOS Push Notifications

APNS (Apple Push Notification Service) is a platform service which is created by Apple Inc. This service enables developers to send push notifications in iOS devices. For this, you must have a Paid Apple Developer. Please follow below steps to create .p12 certificate require to send push notifications -


1. First login in your apple developer account by using this URL: https://developer.apple.com/account/



2. Now select "Certificates" from the left menu. Click on the "+" button from the right.



3. Now select “Apple Push Notification service SSL (Production)” and click “Continue” button -



4. Now, select the app ID from Drop down list and click on “Continue” -



5. Now we need to create CSR. To create CSR follow the steps under “About Creating a Certificate Signing Request (CSR)” -



6. Now upload ".certSigningRequest" file which you have generated (in Step 5), then click on "Generate" button -



7. Now click on "Done" to finish the registration process, The page will be refreshed and you will able to see the download option for this -


After downloading the certificate just double click on downloaded file. This will add the certificate in your keychain access. 

8. Now open “Keychain” in your system, look for the certificate you have just installed in step 7. If you are not sure which certificate that was - That should start with “Apple Production IOS Push Services” and followed by app’s bundle ID.




9. Now, Expand the certificate, you should able to see the private key with your name or your company name. Select both items by using the "Select" key on your keyboard. Now right click and choose “Export 2 items” -



Then save this p12 file with a valid name like "pushcert.p12" to your Desktop. Now you will be prompted to enter a password to protect this p12 file, You can select skip the password or enter a password option.

10. Now open the terminal and move in your directory where you have this p12 file. Run below command to generate pem file -

openssl pkcs12 -in pushcert.p12 -out pushcerts.pem -nodes -clcerts



Thursday, July 5, 2018

Which Framework Is Better for Cross-Platform / Hybrid Mobile App Development? (Ionic Vs. React Native)

Ionic Vs. React Native : 

The objective of this post is to inform the most important differences between Ionic (2,3,4) and React Native, This artical will hopefully give you the information you need to make an educated choice about the stack that will work best for your project.

When you start to use new technology, you cannot be sure it will be the best solution. In some cases, some issues are through time duration and number of apps/projects. In this post, I am going to show a comparison between two frameworks, which are React Native and Ionic. I will explain based on my real time experience in app  development.
Now a days there are so many hybrid mobile frameworks are available, such as Ionic, NativeScript, React Native, Xamarin, PhoneGap. But according to me there are top 2 hybrid frameworks are available and which are — Ionic and React Native









Ionic Overview 
Ionic is an open source, cross-platform framework used to develop hybrid mobile applications. Ionic is a mobile app development framework based on the HTML5 programming language. The HTML5 framework always works with the help of Cordova or PhoneGap. Hence, Ionic needs both of them.
Ionic is the only mobile / hybrid app framework that easily allow web developers to build mobile apps for all major app stores and the mobile web with a single code base. And with Ionic’s Platform Continuity, your app looks and feels at home on every device. Ionic community has developed more than 4M ionic apps.

  1. Ionic has free & Open Source — 100% source code on Github
  2. Ionic is fully Cross-Platform  framework. Which can be used for IOS, Android,     Windows, Web, Desktop, PWA.
  3. Ionic is premier Native Plugins — Camera, Bluetooth, Push Notifications
  4. Ionic is first-class Documentation — Clear and Consistent




Advantages of the Ionic Framework
  1. Fast development-testing cycle.
  2. It cross-compiles to iOS and Android.
  3. It is platform independent whether it has to work with HTML, CSS, JS, or AngularJS.
  4. Ionic is easy to learn & work with.
  5. In ionic you can write code in TypeScript (like angular 2,3,4 code), which makes it easy if you are having experience of AngularJS 2/3/4.
  6. In ionic you can easily use TypeScript (like angular2) to develop applications for all platforms.
  7. You can access the native functionalities of your user’s devices with the plugin system.
  8. Angular itself is easier to learn & work with, for smaller projects than React.





React Native Overview

The goal of React Native framework is not to provide a way to write once, and run everywhere. Rather, React Native want all developers to use the components which is best for the native behaviors of the all platforms. For example, Android has a highly customizable toolbar but iOS does not have this. You can use the toolbar for Android but you need to use something different for iOS platform. 

React Native is a JavaScript library that is used to develop UI. React Native Framework is fully managed and maintained by a community of expert React Native developers and leading corporations, including Facebook and Instagram. It helps all mobile apps developers to reuse the code which is already used in any Android or iOS apps.

Advantages of React Native
  1. React Native framework is developed by a very good and strong community of developers and corporations, which helps all developers to make speed up the learning and development process of there application.

  2. React Native has response time that could be compared to native apps.
  3. React Native has ability to reuse the code parts (not all code) for desktop (web apps) and mobile (mobile apps) and even for the server. 
  4. React Native has quickly develop and debug the app functionality.
  5. React Native has big amount of elaborated components from Facebook.
  6. React Native has even bigger amount of components from community.
  7. React Native allows developers to reuse existing code, it makes it very speedy to deliver the apps.




Ionic vs. React Native:

If you want to select development tool for your hybrid app from these two options, You need to definitely familiarize yourself with the all key features that makes Ionic and React Native different with each other.

However, I can just tell you which one I batter. It is React Native. I personally suggest the native rendering more than the other things. According to me, Apps speed need to be extremely fast, smooth and responsive, Also in React Native, I have found a good compromise between writing pure native code, or pure hybrid apps. This is the best part of rect native.
Now, According to me my best advise to you is : You should try them out both and pick one which is easy to use according to your requirements and make the best out of it!