Package Exports
- @marsidev/react-turnstile
Readme
Features
- 💪 Smart verification with minimal user interaction
- 🕵️♀️ Privacy-focused approach
- 💉 Automatic script injection
- ⚡️ SSR ready
- 💻 TypeScript support
Docs | Demo
Getting started
- Follow these steps to obtain a free site key and secret key from Cloudflare.
- Install
@marsidev/react-turnstileinto your React project.
npm i @marsidev/react-turnstileUsage
import { Turnstile } from '@marsidev/react-turnstile'
function Widget() {
return <Turnstile siteKey='1x00000000000000000000AA' />
}Checkout the docs for more examples and for a detailed info about the
Turnstileprops.
Checkout the demo for a live example.
Contributing
Any contributions are greatly appreciated. If you have a suggestion that would make this project better, please fork the repo and create a Pull Request. You can also open an issue.
Development
- Fork or clone this repository.
- Install dependencies with
pnpm install. - You can use
pnpm devto start the demo page in dev mode, which also rebuild the library when file changes are detected in thepackages/libfolder.
The library is written under the
packages/libfolder, the demo page is under thedemos/nextjsfolder and the docs are under thedocsfolder.
Contributors
Credits
Inspired by
Support
If you like this project, please consider supporting it through a PayPal donation. 😊
License
Published under the MIT License.