diff --git a/components/form/index.en-US.md b/components/form/index.en-US.md index 4ebf0ed6ef..9453155afd 100644 --- a/components/form/index.en-US.md +++ b/components/form/index.en-US.md @@ -99,7 +99,7 @@ If you use `react@<15.3.0`, then, you can't use `getFieldDecorator` in stateless |-----------|-----------------------------------------|------|---------------| | id | The unique identifier is required. support [nested fields format](https://github.com/react-component/form/pull/48). | string | | | options.valuePropName | Props of children node, for example, the prop of Switch is 'checked'. | string | 'value' | -| options.initialValue | You can specify initial value, type, optional value of children node. | | n/a | +| options.initialValue | You can specify initial value, type, optional value of children node. (Note: Because `Form` will test equality with `===` internaly, we recommend to use vairable as `initialValue`, instead of literal) | | n/a | | options.trigger | When to collect the value of children node | string | 'onChange' | | options.getValueFromEvent | To convert parameters of onChange to the value of control | function(..args) | [reference](https://github.com/react-component/form#optiongetvaluefromevent) | | options.validateTrigger | When to validate the value of children node. | string\|string[] | 'onChange' | diff --git a/components/form/index.zh-CN.md b/components/form/index.zh-CN.md index 8df84701cd..3c3889932b 100644 --- a/components/form/index.zh-CN.md +++ b/components/form/index.zh-CN.md @@ -100,7 +100,7 @@ CustomizedForm = Form.create({})(CustomizedForm); |-----------|-----------------------------------------|-----|--------| | id | 必填输入控件唯一标志。支持嵌套式的[写法](https://github.com/react-component/form/pull/48)。 | string | | | options.valuePropName | 子节点的值的属性,如 Switch 的是 'checked' | string | 'value' | -| options.initialValue | 子节点的初始值,类型、可选值均由子节点决定 | | | +| options.initialValue | 子节点的初始值,类型、可选值均由子节点决定(注意:由于内部校验时使用 `===` 判断是否变化,建议使用变量缓存所需设置的值而非直接使用字面量)) | | | | options.trigger | 收集子节点的值的时机 | string | 'onChange' | | options.getValueFromEvent | 可以把 onChange 的参数转化为控件的值 | function(..args) | [reference](https://github.com/react-component/form#optiongetvaluefromevent) | | options.validateTrigger | 校验子节点值的时机 | string\|string[] | 'onChange' |