0.1.6 • Published 8 months ago

solid-grecaptcha v0.1.6

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

Solid-gRecaptcha

Package based on solid-hcaptcha using g-recaptcha of google

Sign up at g-rcaptcha to get your sitekey today. You need a sitekey to use this library.

  1. Installation
  2. Implementation
  3. References

Installation

# npm
npm install solid-grecaptcha

# yarn
yarn add solid-grecaptcha

Implementation

import GRecaptcha from "solid-grecaptcha";

const App: Component = () => {

  return (
    <GRecaptcha
      sitekey=""
      onVerify={token => console.log(token)}
    />
  );
};

export default App;

References

Props

NameValues/TypeRequiredDefaultDescription
sitekeystringYes-This is your sitekey, this allows you to load captcha. If you need a sitekey, please visit g-recaptcha, and sign up to get your sitekey.
size"normal" \| "compact"No"normal"This specifies the "size" of the component. g-recaptcha allows you to decide how big the component will appear on render, this always defaults to normal.
theme"light" \| "dark"No"light"g-recaptcha supports both a light and dark theme. If no theme is inherently set, the captcha will always default to light.
tabindexnumberNo0Set the tabindex of the widget and popup. When appropriate, this can make navigation of your site more intuitive.

Events

NameParamsDescription
onVerifytoken:stringExecuted when user submits a successful response
onError-Executed when recaptcha find an error
onExpire-Executed when response expires and the user needs to re-verify
0.1.6

8 months ago

0.1.5

8 months ago

0.1.4

8 months ago

0.1.3

8 months ago

0.1.2

8 months ago

0.1.1

8 months ago

0.1.0

8 months ago