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
In the onNameChange(event) function you take an event and is supposed to use that event to update the state.
The working solutions, for the tests, is to explicitly name the key, ie: this.setState({name: event.target.value});
But, if you want to be more general, and you don't want to explicitly say that it's the "name" attribute that should always be updated, you can do this:
Exercise 03, task 1.
In the
onNameChange(event)
function you take an event and is supposed to use that event to update the state.The working solutions, for the tests, is to explicitly name the key, ie:
this.setState({name: event.target.value});
But, if you want to be more general, and you don't want to explicitly say that it's the "name" attribute that should always be updated, you can do this:
Which works great in the browser, but fails in the tests.
Is there a specific reason for this that I'm missing?
The text was updated successfully, but these errors were encountered: