Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
7385b36
feat: createFormControl outside of component
xeka0 Feb 17, 2024
35307ca
first draft api
xeka0 Feb 17, 2024
f629475
improved type check
xeka0 Feb 17, 2024
61b4c6d
update api contract
xeka0 Feb 17, 2024
ac427ec
fix build
xeka0 Feb 17, 2024
11449e6
useForm impl complete with subscribe
xeka0 Feb 18, 2024
712a096
split values and other formState sub
xeka0 Feb 18, 2024
6994cf8
integrate with useForm
xeka0 Feb 18, 2024
885e8e0
fix render root issue
xeka0 Feb 18, 2024
7b28b12
integrate with useFormState
xeka0 Feb 18, 2024
7a766ba
fix subscription with formState
xeka0 Feb 18, 2024
18cc901
include useWatch integration
xeka0 Feb 18, 2024
d7f99a0
remove useSubscribe
xeka0 Feb 18, 2024
0bea0b2
fix lint error
xeka0 Feb 18, 2024
d35fb79
remove useFieldArray unregister
xeka0 Feb 18, 2024
674c07d
merge subscription to single state
xeka0 Feb 18, 2024
a24febd
update api contract
xeka0 Feb 18, 2024
59a76e2
remove NestedValue
xeka0 Feb 18, 2024
c5474b7
remove nested value and expose the create form control method
xeka0 Feb 18, 2024
c948248
update api contract and fix build
xeka0 Feb 18, 2024
e9936ab
fix app build
xeka0 Feb 18, 2024
a5e1c63
fix issue with missing formState
xeka0 Feb 24, 2024
261b406
Merge branch 'master' into feat/createFormControl
xeka0 Feb 24, 2024
42b3039
update with tests coverage
xeka0 Feb 24, 2024
6f1f818
fix build
xeka0 Feb 24, 2024
fe62d32
update api contractor
xeka0 Feb 24, 2024
f4dc464
Merge branch 'master' into feat/createFormControl
xeka0 Feb 24, 2024
1f6ba35
seperate proxy subscription between hook and subscribe function
xeka0 Feb 24, 2024
7de1d87
update package size
xeka0 Feb 25, 2024
8d974b4
remove unused method
xeka0 Feb 25, 2024
40c34e9
remove unused method
xeka0 Feb 25, 2024
9c05c50
update all export json
xeka0 Feb 25, 2024
f991ef8
update api contractor
xeka0 Feb 25, 2024
dd6f726
fix build
xeka0 Feb 25, 2024
3f2796c
Merge branch 'master' into feat/createFormControl
xeka0 Feb 25, 2024
0f46873
Merge branch 'master' into feat/createFormControl
xeka0 Mar 1, 2024
b9c1821
minor code improvement
xeka0 Mar 17, 2024
788dad2
Merge branch 'master' into feat/createFormControl
xeka0 Mar 17, 2024
1cab3aa
fix code format
xeka0 Mar 17, 2024
9215713
Merge branch 'master' into feat/createFormControl
xeka0 Apr 6, 2024
917654f
🐞 fix #11773 regression on dirty check with reset (#11775)
xeka0 Apr 11, 2024
234d32d
7.51.3
xeka0 Apr 11, 2024
071b1e7
🩻 update README.md (#11776)
xeka0 Apr 12, 2024
01e75d3
👹 close #11778 improve unregister omit key with getValues method (#11…
xeka0 Apr 14, 2024
e37dc15
7.51.4
xeka0 May 4, 2024
020b06f
📖 fix broken link to examples in README.md (#11805)
xeka0 May 4, 2024
736d159
⌨️ close: correct type of `error` field in `getFieldState` return obj…
xeka0 May 5, 2024
7bf8fc4
Merge branch 'master' into feat/createFormControl
xeka0 May 5, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<a href="https://react-hook-form.com/docs">API</a> |
<a href="https://react-hook-form.com/form-builder">Form Builder</a> |
<a href="https://react-hook-form.com/faqs">FAQs</a> |
<a href="https://github.com/bluebill1049/react-hook-form/tree/master/examples">Examples</a>
<a href="https://github.com/react-hook-form/react-hook-form/tree/master/examples">Examples</a>
</p>

### Features
Expand Down Expand Up @@ -58,10 +58,6 @@ function App() {
}
```

<a href="https://ui.dev/bytes/?r=bill">
<img src="https://raw.githubusercontent.com/react-hook-form/react-hook-form/master/docs/ads-1.jpeg" />
</a>

### Sponsors

Thanks go to these kind and lovely sponsors!
Expand Down
4 changes: 2 additions & 2 deletions app/src/autoUnregister.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useState } from 'react';
import ReactSelect from 'react-select';
import { useForm, Controller, NestedValue } from 'react-hook-form';
import { useForm, Controller } from 'react-hook-form';

const options = [
{ value: 'chocolate', label: 'Chocolate' },
Expand All @@ -15,7 +15,7 @@ export default function AutoUnregister() {
test2: boolean;
test3: string;
test4: string;
ReactSelect: NestedValue<{ label: string; value: string }>;
ReactSelect: { label: string; value: string };
}>();
const [show, setShow] = useState(true);

Expand Down
4 changes: 2 additions & 2 deletions app/src/basic.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useState } from 'react';
import { useForm, NestedValue, ValidationMode } from 'react-hook-form';
import { useForm, ValidationMode } from 'react-hook-form';
import { useParams } from 'react-router-dom';

let renderCounter = 0;
Expand All @@ -25,7 +25,7 @@ const Basic: React.FC = () => {
pattern: string;
radio: string;
checkbox: string;
checkboxArray: NestedValue<string[]>;
checkboxArray: string[];
multiple: string;
validate: string;
nestItem: {
Expand Down
4 changes: 2 additions & 2 deletions app/src/defaultValues.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { NestedValue, useForm } from 'react-hook-form';
import { useForm } from 'react-hook-form';

function DefaultValues() {
const { register } = useForm<{
Expand All @@ -11,7 +11,7 @@ function DefaultValues() {
nest: string;
};
};
checkbox: NestedValue<string[]>;
checkbox: string[];
}>({
defaultValues: {
test: 'test',
Expand Down
6 changes: 3 additions & 3 deletions app/src/setValue.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useEffect } from 'react';
import { useForm, NestedValue } from 'react-hook-form';
import { useForm } from 'react-hook-form';

let renderCounter = 0;

Expand All @@ -18,14 +18,14 @@ const SetValue: React.FC = () => {
checkboxArray: string[];
radio: string;
select: string;
multiple: NestedValue<string[]>;
multiple: string[];
array: string[];
object: {
firstName: string;
lastName: string;
middleName: string;
};
nestedValue: NestedValue<string[]>;
nestedValue: string[];
}>();

useEffect(() => {
Expand Down
181 changes: 0 additions & 181 deletions cypress/e2e/useFieldArrayUnregister.cy.ts

This file was deleted.

4 changes: 2 additions & 2 deletions examples/V7/nativeMultipleInput.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React from 'react';
import { useForm, NestedValue } from 'react-hook-form';
import { useForm } from 'react-hook-form';

export default function App() {
const {
register,
formState: { errors },
handleSubmit,
} = useForm<{
email: NestedValue<string[]>;
email: string[];
}>({
defaultValues: {
email: ['first@react.hook.form', 'last@react.hook.form'],
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "react-hook-form",
"description": "Performant, flexible and extensible forms library for React Hooks",
"version": "7.51.2",
"version": "7.51.4",
"main": "dist/index.cjs.js",
"module": "dist/index.esm.mjs",
"umd:main": "dist/index.umd.js",
Expand Down Expand Up @@ -118,7 +118,7 @@
"files": [
{
"path": "./dist/index.cjs.js",
"maxSize": "10.1 kB"
"maxSize": "10.5 kB"
}
]
},
Expand Down
Loading