NestedLink icon indicating copy to clipboard operation
NestedLink copied to clipboard

Validation don't reevaluates when a dependent state changes

Open mcaballeropinto opened this issue 7 years ago • 1 comments

Hi there!

I have a validation for a link that uses a different state property (not the one associated to the link I'm validating). When that external state property changes, the validation doesn't rerun. This leaves the link error property in a not trustworthy state. The external state property may leave the link with an error but I won't know until the state associated with the link changes.

A workaround for this would be having a mechanism to run validation on a link manually, but I couldn't find a way to do so. Any other suggestions?

Thanks in advance!

mcaballeropinto avatar Nov 20 '17 05:11 mcaballeropinto

Hi. Links are meant to be immutable and to be recreated again in render(). That applies to validation as well.

It would be very helpful if you provide the code example. Looking at the example I could say something less general.

gaperton avatar Nov 20 '17 18:11 gaperton