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
is the result of with immutable? and if I call with on the same field a second time will the new value replace the old? how does this work with deeply nested objects/arrays? what if I don't have a no-args constructor?
I think it's worth addressing these in the documentation
The text was updated successfully, but these errors were encountered:
with mutates any fields and replaces the old value with new one. For example if user name was 'John' and you write .with({ name: 'Jim' }) It will replace the old value with new one.
If you don't have an empty constructor it's not a problem. You create your object however you want and mutate its fields using with method.
is the result of
with
immutable? and if I call with on the same field a second time will the new value replace the old? how does this work with deeply nested objects/arrays? what if I don't have a no-args constructor?I think it's worth addressing these in the documentation
The text was updated successfully, but these errors were encountered: