I make a Phone Authentication page using React-Native and thought that to store the data in firebase so, security purpose I will add a reCaptcha that who fill the reCaptcha they can click the the verify button otherwise no. But when I install this package: npm install react-native-google-recaptcha-v2, I got some error. How can I add reCaptcha ?enter image description here
You have used
npm install react-native-google-recaptcha-v2,
so instead of that If you have yarn installed then you can try this
yarn add react-native-google-recaptcha-v2.
Basically, this library is very old so there are version conflicts while using yarn that will manage all things.
react-native-google-recaptcha-v2is a very old library so you can try https://www.npmjs.com/package/react-native-recaptcha-that-works, maybe this will work for you.
You need to create a project with react version 16.9 and then it works with react-native-google-recaptcha-v2.
react-native-google-recaptcha-v2 lib is too old and not maintained with new React version. You can use latest one react-native-recaptcha-that-works.
You can use the latest library
react-native-recaptcha-that-works
Related
I have existing react-native project and I want to use expo-in-app-purchases module, and can't find clear doc how to do that. unimodules from its README are deprecated, and not sure that migration is the right one.
I want only one module, without migrating to expo.
In order to use 'expo-in-app-purchases' you have to install Expo modules, as stated in docs:
You must ensure that you have installed and configured Expo modules before continuing.
It doesn't mean that you have to migrate the whole project to expo. There are two scenarios:
You don't have Expo modules in your project: use automatic installation,
You have react-native-unimodules installed: migrate to Expo modules using this guide
I have used two social login and both are refers the react-native-webview dependency.
installed versions:
react-native-linkedin(it uses react-native-webview 7.0.5),
react-native-instagram-login (it uses react-native-webview 7.5.1),
react-native-webview ^7.5.1
Can you please tell me how to resolve this issue
screenshot
https://i.stack.imgur.com/ETW5J.png
facing same issue with same library . It is cause of different versions of webview which these library are using and as much as i know we can update those npm module directly so we can solve this issue temporary by following these steps
Create file InstaWebView.js(name can be any)
Copy code from
https://github.com/hungdev/react-native-instagram-login/blob/master/Instagram.js
Paste in InstaWebView.js and use as normal
I know it is hack but for now we can do this
Note :- For this hack , you need to install webview module so you may install webview module of same version as linkedin has so there will be no issue
i'm trying to use 'react-native-video' in my application, i have used the following lines to get it:
npm install --save react-native-video
react-native link react-native-video (since my react native version is 0.59)
after doing so and using "Video" component from 'react-native-vide' i got an error like below:
what is the problem? what can i do? any ideas?
You did not link the library properly.
After having installed the library through npm i --save react-native-video, you'll need to run react-native link react-native-video in order to link it. This may or may not work - if it does not, you'll need to link manually according to the installation instructions of the library.
You might be using CocoaPods in which case you'll need to run these commands as well: cd ios && pod install
If you receive an error, you're most likely not using CocoaPods and this is the wrong approach.
Please note that you'll need to reinstall the app on the phone / simulator afterwards since you've changed the native dependencies. You'll also need to do this if you're using (ejected) Expo or anything alike. If you're using Expo with the managed workflow (= not ejected) you're not able to use libraries that depend on native linking.
I am creating a react-native application. Here I am creating one library on npm as well. And using this library from my react application inside package.json.
Now, I want to automate one task here. If I update the code and version of my library on npm, my react-native application should adopt the new version automatically.
How could I achieve this task?
Any ideas regarding same?
Thanks in advance.
If your library is on any remote server and you have added it into your project using package manager (like yarn).
Now you have updated your library but it will not update automatically in your react native project.
You have to achieve this manually by specifying the library version.
yarn add package-name#1.2.3
Refer: package using yarn
In my cases when i link third party module in react native like..
npm install react-native-vector-icons --save.
react-native link
It gives message for me....
React Native CLI uses autolinking for native dependencies, but the following modules are linked manually:-
react-native-vector-icons (to unlink run: "react-native unlink react-native-vector-icons")
but if i am not link the module it will not work for me
this problem occurs only in react-native new upgraded version(0.60) not for older version.
please suggest me any solution for the given problem.
Always make sure to install any third party library manually rather than doing react-native link.
Follow the detailed manual installation https://github.com/oblador/react-native-vector-icons from here.
Firstly run this command react-native unlink react-native-vector-icons
After unlink is successful, follow the manual installation steps.
Also it's better to use yarn (https://yarnpkg.com/en/) over npm while installing a package.
Hope this helps!
Since react native 0.60 auto-linking is avaliable so that means that future libraries release won't need to run the "link" command. If you're using vector-icons you'll need to wait until the upgrade. You can use the vector icons linked to you project normally, but be careful because that will not be compatible in the next major release in react native. I also tried to upgrade to react native 0.60.3, but this is not the great idea if your using a lot of dependencies.