react-hook-form-mantine
Version:
React hook form wrapper for Mantine components
35 lines (22 loc) • 915 B
Markdown
# React-Hook-Form-Mantine
React-Hook-Form-Mantine is a library that simplifies the integration of Mantine components with React Hook Form. By adding a "name" prop to Mantine components, the library seamlessly connects them to the corresponding form field.
## Demo
- <https://aranlucas.github.io/react-hook-form-mantine>
- <https://codesandbox.io/s/react-hook-mantine-krflqj?file=/src/App.tsx>
## Getting Started
```bash
npm install react-hook-form-mantine react-hook-form @mantine/core @mantine/dates dayjs
```
### Peer dependencies
This package requires the following peer dependencies:
| Package | Version |
| ----------------- | --------- |
| `@mantine/core` | `^9.0.0` |
| `@mantine/dates` | `^9.0.0` |
| `react` | `^19.0.0` |
| `react-dom` | `^19.0.0` |
| `react-hook-form` | `^7.43` |
## Usage/Examples
Check [example usage](/example/src/App.tsx)
## License
MIT