Default Values not working as expected #7058
-
hi, I m facing an issue related to default values as I set the data which is coming from the API and set it to the default values . I m also resetting the values but I can't see the values on the fields and the same problem for dropdowns also. i m using Next js and Material UI for the frontend. Use FormInput Fields |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 14 replies
-
provide a codesandbox? |
Beta Was this translation helpful? Give feedback.
-
Hello, Default values will not work if you are using a custom component, though you can pass them using states like this:
i.e. here user_temp contains the default values.
|
Beta Was this translation helpful? Give feedback.
-
I discovered that it's also possible to use a custom select component (that doesn't use a native
|
Beta Was this translation helpful? Give feedback.
Hello, Default values will not work if you are using a custom component, though you can pass them using states like this:
i.e. here user_temp contains the default values.
and then use them like this: