@easylabs/react
v1.0.0
Published
Easy Labs SDK for React
Maintainers
Readme
Easy React SDK
The Easy React SDK provides a simple, type-safe, and PCI/PII-compliant way to integrate Easy's payment and customer management platform into your React applications.
📚 View Full Documentation & Examples →
Features
- Create and manage customers
- Tokenize and create payment instruments (cards, bank accounts)
- Initiate transfers and payments
- Anonymous checkout flows
- TypeScript-first API
- PCI/PII compliant: secure form elements protect sensitive data
- Flexible: use existing payment instrument or create new
Installation
pnpm add @easylabs/react
# or
npm install @easylabs/react
# or
yarn add @easylabs/reactUsage Example
import { EasyProvider, useEasy } from "@easylabs/react";
function App() {
return (
<EasyProvider apiKey={import.meta.env.VITE_EASY_API_KEY!}>
<MyCheckoutComponent />
</EasyProvider>
);
}Note: For Next.js projects, use
process.env.NEXT_PUBLIC_EASY_API_KEYinstead.
API Reference
EasyProvider
Wrap your app with EasyProvider and provide your Easy API key.
useEasy()
Access all SDK methods via the context:
TypeScript Support
All types are exported for maximum type safety and autocompletion.
PCI/PII Compliance
Built with secure form elements for PCI-compliant payment data collection. Your application never touches sensitive payment information.
Contributing & Support
For issues, questions, or contributions, please open an issue or pull request on GitHub.
