calling setState in the widget resets the form. #1134
Labels
awaiting author response
Waiting for author of issue to respond with more info
bug
Something isn't working
I would like to toggle visibility of fields depending on the value of a checkbox (#316).
I am trying to set the state of a seperate variable, but everytime I call setState the state of the form resets to its initial state.
I defaulted a variable and toggle it via setState. everytime setState is called the form resets
the following attempt using
FormBuilderCheckbox
didn't reset the form, but never updates the checkbox state (ie setsate for the form is not called)curious if I am doing something incorrect. or how i could toggle the visability of a field (external variable or internal)
using
_formKey.currentState?.value["same_hours"]
never updated the visibilityThe text was updated successfully, but these errors were encountered: