form icon indicating copy to clipboard operation
form copied to clipboard

fix for getFieldValue creating a new field in fieldMeta issue

Open lulut opened this issue 7 years ago • 2 comments

Trying to fix this issue: https://github.com/react-component/form/issues/181

lulut avatar Jul 25 '18 08:07 lulut

Copied from issue log for your convenience:

https://codesandbox.io/s/50x3l7y59n

Steps to reproduce

  1. click "Add field" button
  2. new row will be created with no issue
  3. click "Error Button" button, no impacts to the function since the "list" variable has been initialized as an Array correctly.
  4. reload the page
  5. this time click "Error Button" first.
  6. a new field "list" will be added to fieldMeta
  7. click "Add field" button
  8. error occurred because list is an 'object' instead of 'Array'

lulut avatar Jul 25 '18 08:07 lulut

image

I don't why the check failed at coverage step. Can anyone have a look on this?

lulut avatar Aug 16 '18 09:08 lulut