gerhat / material-ui-formik-components

Formik ready material ui components
MIT License
85 stars 13 forks source link

InivitalValues not displayed with AutoComplete component. #28

Closed pzapo closed 4 years ago

pzapo commented 4 years ago

Passing initialValues to formik Field component with AutoComplete is broken. InitialValues are not rendered on AutoComplete component but when save is clicked then they are available in values formik variable.

Here is link to sample code based on your example from documentation: https://codesandbox.io/s/goofy-wildflower-i3h1r

dalborgo commented 4 years ago

The same problem for me.

gian788 commented 4 years ago

Same issue for me too

gerhat commented 4 years ago

Thank you for reporting @pzapo @dalborgo and @gian788. It is indeed an issue. Will fix asap.

shtjefeen commented 4 years ago

@gerhat Did u get this fixed!

shtjefeen commented 4 years ago

@gerhat I created a pull request for this one

gerhat commented 4 years ago

Issue fixed in v0.6.2.

Here is an example on how to pass initial values to autocomplete.

const initialValues = {
  skills: [
    {
      label: 'ASP.NET',
      value: 'ASP.NET',
    },
  ],
}