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
Because technically newState does not mutate it's value. Changing a prop in the object does not mean changing the value of the variable so no runtime errors. In practice you should use something like ImmutableJS to avoid mutating object but we are not doing it here for simplicity.
Why newState is defined as const and in next line you're assigning new field prop to it?
The text was updated successfully, but these errors were encountered: