React + Antd problems encountered

Form

mapPropsToFields

export default Form.create({  mapPropsToFields: (props: any) => ({    workId: Form.createFormField({      value: props.data.workId    }),    orderId: Form.createFormField({      value: props.data.orderId    })  })})(Remark);复制代码

Use this method to map the props in the fields to the form field time, during storage, the form is reset.

Request and use axios redux were loading management, so every request in a modified state Redux Loading and thus will lead to re-form updates.

Why does this happen?


Reproduced in: https: //juejin.im/post/5cf0f773e51d45108c59a4e6

Guess you like

Origin blog.csdn.net/weixin_34037515/article/details/91432807