{"repo":"hCaptcha/react-hcaptcha","free":true,"listed":false,"github":"https://github.com/hCaptcha/react-hcaptcha","clone":"git clone https://github.com/hCaptcha/react-hcaptcha.git","description":"hCaptcha Component Library for ReactJS and Preact","language":"TypeScript","stars":615,"topics":["reactjs","react","hcaptcha","captcha"],"license":"MIT","category":"ui-components","readme_excerpt":"React hCaptcha Component Library hCaptcha Component Library for ReactJS. hCaptcha is a drop-replacement for reCAPTCHA that protects user privacy. Sign up at hCaptcha to get your sitekey today. You need a sitekey to use this library. Also compatible with Preact. 1. Installation 2. References 3. Debugging 4. Contributing Installation You can install this library via npm with: Implementation The two requirements for usage are the sitekey prop and a parent component such as a . The component will automatically include and load the hCaptcha API library and append it to the parent component. This is designed for ease of use with the hCaptcha API! Standard Programmatic In the event you want to call the hCaptcha client API directly, you can do so by using the hook useRef and waiting for onLoad to be called. By waiting for onLoad the hCaptcha API will be ready and the hCaptcha client will have been setup. See the following example: Typescript Support \\ If you want to reassign the component name, you could consider making a util that imports the component, then re-exports it as a default. Provider/Hook Pattern You can also use the Provider/Hook pattern: Provider Props Name Values/Type Required Default Description --- --- --- --- --- sitekey String Yes - Your hCaptcha sitekey. size String (normal, compact, invisible) No normal The size of the hCaptcha widget. theme String (light, dark) No light The theme of the widget. rqdata String No - See enterprise docs. languageOverride String No -","default_branch":null,"files":null,"tree":[],"storefront":"/r/hCaptcha","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/hCaptcha/react-hcaptcha/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}