Skip to content

State not updating inside Formik render function #220

Description

@levani

React Easy State version: 6.3.0
Platform: browser / react-native

Describe the bug
When I'm displaying a state inside Formik render function, if the state is updated the component is not re-rendering properly. For some reason I have to trigger the update second time to cause the re-render.

Here is a working example: https://codesandbox.io/s/compassionate-https-0jlp6?file=/src/App.js

You will have to click the submit button twice to change the text from "false" to "true".


For tougher bugs

To Reproduce

Expected behavior
The text next to the button should become "true" after one click.


For the toughest bugs only

CodeSandbox reproduction
https://codesandbox.io/s/compassionate-https-0jlp6?file=/src/App.js

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions