You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I've noticed the following unexpected behavior:
When using transform() with default() there is inconsistency in returned value between undefined and {} input.
In the other case, the input is not undefined, so the default object isn't used but value is still undefined. Since there is no value to process no transforms are run, and you just get the default
Describe the bug
Hi, I've noticed the following unexpected behavior:
When using
transform()
withdefault()
there is inconsistency in returned value betweenundefined
and{}
input.To Reproduce
Full test suite:
https://codesandbox.io/s/yup-transform-with-default-inconsistency-3tewl?file=/index.test.ts
Expected behavior
The same value for each case - either default value with or without transformation applied.
The text was updated successfully, but these errors were encountered: