MCPcopy Create free account
hub / github.com/react-hook-form/react-hook-form / Section1

Function Section1

examples/V6/nestedFields.tsx:7–28  ·  view source on GitHub ↗
({ register })

Source from the content-addressed store, hash-verified

5import FormSection2 from './formSection2';
6
7export default function Section1({ register }) {
8 return (
9 <>
10 <div>
11 <label>First name</label>
12 <input
13 type="text"
14 name="First name"
15 ref={register({ required: true, maxLength: 80 })}
16 />
17 </div>
18 <div>
19 <label>Last name</label>
20 <input
21 type="text"
22 name="Last name"
23 ref={register({ required: true, maxLength: 100 })}
24 />
25 </div>
26 </>
27 );
28}
29
30export default function formSection2({ register }) {
31 return (

Callers

nothing calls this directly

Calls 1

registerFunction · 0.85

Tested by

no test coverage detected