diff --git a/examples/list.tsx b/examples/list.tsx index 76a08a78..16e5aed9 100644 --- a/examples/list.tsx +++ b/examples/list.tsx @@ -25,8 +25,20 @@ const Demo = () => { > {() => JSON.stringify(form.getFieldsValue(), null, 2)} - - {(fields, { add, remove }) => { + { + if (value.length < 2) { + throw new Error(); + } + }, + }, + ]} + > + {(fields, { add, remove }, { errors }) => { console.log('Demo Fields:', fields); return (
@@ -49,6 +61,12 @@ const Demo = () => { ))} +
    + {errors.map(err => ( +
  • {err}
  • + ))} +
+