Skip to content

Conversation

@vvasin
Copy link
Contributor

@vvasin vvasin commented Jun 28, 2024

By default, dynamic forms clear the final form field value on unmount. This should be configurable. The name of the property and its description comes from the final form docs

@gravity-ui-bot
Copy link
Contributor

Preview is ready.

@gravity-ui-bot
Copy link
Contributor

Playwright Test Component is ready.

}
};
}, []);
}, [destroyOnUnregister]);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

here this flag should not cause an effect, its value will be relevant in the callback, this is the main thing that we need

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its value will be relevant in the callback

I don't think so, on "unmount" it will have the first value provided in this case, and it will be not updated on prop change.

But generally, yes, the "logic part" shouldn't be triggered by its value change. And most likely it won't be changed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so, on "unmount" it will have the first value provided in this case, and it will be not updated on prop change.

Oh, you're right, we'll have to go back to this place and make the flag and store.name the callback was relevant

@vvasin vvasin merged commit d2b7ce6 into main Jul 1, 2024
@vvasin vvasin deleted the destroy-on-unregister-option branch July 1, 2024 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants