https://github.com/diogomartino/react-n-forms
https://github.com/diogomartino/react-n-forms
Last synced: 6 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/diogomartino/react-n-forms
- Owner: diogomartino
- License: apache-2.0
- Created: 2024-12-11T23:57:22.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2024-12-12T00:11:58.000Z (6 months ago)
- Last Synced: 2024-12-12T00:18:58.343Z (6 months ago)
- Language: TypeScript
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# React N Forms
This is currently in alpha. **Please do not use in production.**
## Simple usage
```jsx
const MyForm = () => {
const [errors, setErrors] = useState({
name: 'You cannot be named John Doe'
});const onSubmit = (values) => {
console.log(values);
};return (
{({ value, onChange, name, error }) => (
Name
{error && {error}}
)}
Submit
);
};
```