'Formik Value not updated after get value form API

I have an issue in updating input value after get value form external API in formik form in react. I get the value of the input field from API and the value sets to the input correctly. But my Issues in whenever I want to change the value in the input nothing happens and value not updated. I make a codesandbox sample here. I would be really appreciated If anyone can explain my problem.

Best Regards



Solution 1:[1]

Here's a quick fix, by adding onChange, and pointing initialValues to value:

initialValues={value}

onChange={(e) => setValue(e.target.value)}

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Enfield li