uxcore-form
uxcore-form copied to clipboard
getValues(force) 未传递 force 标记时不应该影响当前校验状态
在自动保存场景中,期望通过 getValues() 或 getValues(false) 时,不要影响当前已经对用户提示的错误状态,静默的把数据返回回来。
看到 https://github.com/uxcore/uxcore-form-field/blob/master/src/FormField.jsx#L134 这里有对 force / instant 做优先级判断。
实际上,直接在 https://github.com/uxcore/uxcore-form/blob/master/src/Form.jsx#L36 中,先行判断 force 为 undefined 时,返回 { values: deepcopy(me.data) } 会有什么问题么?