Add Android Platforms in Facebook Console We will add Android and IOS platform using it so that we can log in on both the platformģ. – Now if you scroll down a bit then you will see an Add Platform option. – Now to click on the Basic under settings and fill the details like Display Name (Which will be the display name at the time of Login Permission), App Logo, etc From there click on the Dashboard option and you will see something like thisĢ. – After filling the form you will be taken to the landing screen. – You will see the following fields to fill You can see the option to create the app in the top right corner. To do that open Facebook Console and create an App there. – To add a “Login via Facebook” feature in our app, we have to register our application package/bundle name at Facebook Console. Steps to Integrate Facebook Login/Sign In in React Native 1. So to install pods use cd ios & pod install & cd. CocoaPods InstallationĪfter the updation of React Native 0.60, they have introduced autolinking so we do not require to link the library but need to install pods. This example is updated for the latest React Native version. This command will copy all the dependencies into your node_module directory, You can find the directory in node_module the directory named react-native-fbsdk. Run the following command npm install react-native-fbsdk -save To install this open the terminal and jump into your project cd ProjectName To use LoginButton, AccessToken, GraphRequest, GraphRequestManager we need to install react-native-fbsdk package/library. Installation of Dependency for Facebook Login This will make a project structure with an index file named App.js in your project directory. Try uninstalling the cli and run the cli using npx. Note If the above command is failing, you may have old version of react-native or react-native-cli installed globally on your pc. If you want to start a new project with a specific React Native version, you can use the -version argument: npx react-native init ProjectName -version X.XX.X If you have previously installed a global react-native-cli package, please remove it as it may cause unexpected issues: npm uninstall -g react-native-cli the following commands to create a new React Native project npx react-native init ProjectName We are going to use react native command line interface to make our React Native App. Getting started with React Native will help you to know more about the way you can make a React Native project. Let’s get started with the Facebook login example. To log in, via Facebook feature in React Native, we will use react-native-fbsdk library which is very simple and easy to integrate. If you are interested in the more social logins then you can also see Example of Google Sign In in React Native. Every application has a login and signup option but if you are integrating the social login into it then it becomes much easier for the users to login without the mess of filing the registration form and confirming via Email or OTP.Īs we all know Facebook is a very popular platform so we will see the example to integrate the Facebook login in our App. Here is an example of Facebook Sign In integration in React Native using Facebook SDK. Facebook Sign In integration in React Native
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |