--- order: 5 title: zh-CN: 嵌套结构与校验信息 en-US: Nest --- ## zh-CN `name` 属性支持嵌套数据结构。通过 `validateMessages` 或 `message` 自定义校验信息模板,模板内容可参考[此处](https://github.com/react-component/field-form/blob/master/src/utils/messages.ts)。 ## en-US `name` prop support nest data structure. Customize validate message template with `validateMessages` or `message`. Ref [here](https://github.com/react-component/field-form/blob/master/src/utils/messages.ts) about message template. ```tsx import { Form, Input, InputNumber, Button } from 'antd'; const layout = { labelCol: { span: 8 }, wrapperCol: { span: 16 }, }; const validateMessages = { required: 'This field is required!', types: { email: 'Not a validate email!', number: 'Not a validate number!', }, number: { range: 'Must be between ${min} and ${max}', }, }; const Demo = () => { const onFinish = values => { console.log(values); }; return (