Hello everyone,
in my App I have a Component A for product insertion. In this component you can click on a "choose category" button that leads you to another Component B where you can pick your product's category (or add a new one).
I want the text value of the Button in Component A to update with the category's name as soon as the user clicks on "select" button on Component B (which also closes the component).
The issue is it works, but the first time the AppState storing the Product info is updated (so the "category" field was empty before) the button's text doesn't refresh correctly and I have to click on the screen to update it.
From the 2nd time, meaning the "category" field in the AppState was not empty, it works as expected.
Below there is a video visually explaining the issue:
(red circle means I clicked with the mouse)