Socket
Socket
Sign inDemoInstall

@haskkor/react-native-recaptchav3

Package Overview
Dependencies
1
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @haskkor/react-native-recaptchav3

React native component to use the invisible recaptcha v3 from Google


Version published
Weekly downloads
425
decreased by-25.31%
Maintainers
1
Install size
387 kB
Created
Weekly downloads
 

Changelog

Source

[1.2.1] - 2020-06-19

Merged

  • Merged johnlim5847 PR (add action props)

Readme

Source

react-native-recaptchav3

npm npm

React native component to use the invisible reCAPTCHA v3 from Google

https://www.google.com/recaptcha/intro/v3.html

Installation

npm install --save @haskkor/react-native-recaptchav3

or

yarn add @haskkor/react-native-recaptchav3

Note: React Native Community Webview requires you to link the native dependencies (https://github.com/react-native-community/react-native-webview/blob/master/docs/Getting-Started.md)

Demo

automatic retrybutton

Usage

Automatically get a captcha token:

import ReCaptchaV3 from '@haskkor/react-native-recaptchav3'

<ReCaptchaV3
  captchaDomain={'https://yourowndomainname.co.nz'}
  siteKey={'yourownsitekey'}
  onReceiveToken={(token: string) => Alert.alert('CAPTCHA', token)}/>

One could also use a trigger to request a new token using the reference of the component:

import ReCaptchaV3 from '@haskkor/react-native-recaptchav3'

<ReCaptchaV3
  ref={(ref: RecaptchaV3) => this._captchaRef = ref}
  captchaDomain={'https://yourowndomainname.co.nz'}
  siteKey={'yourownsitekey'}
  onReceiveToken={(token: string) => Alert.alert('CAPTCHA', token)}/>

<TouchableOpacity onPress={() => this._captchaRef.refreshToken()}>
  <Text>Retry</Text>
</TouchableOpacity>

Options

KeyDescriptionDefaultRequiredType
captchaDomainYour url registered with Google reCAPTCHANonetruestring
onReceiveTokenThe callback used to get the captcha token from the componentNonetrue(captchaToken: string) => void
siteKeyThe site key provided by Google reCAPTCHANonetruestring

Changelog

Contributing

Pull requests are welcome.

License

FAQs

Last updated on 19 Jun 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc