To update an object key in the state select the key and assign its value to that state
onClick={(e) =>
setBooks((prev) => ({
...prev,
physics: e.target.value,
}))
}
To update an object key in the state select the key and assign its value to that state
onClick={(e) =>
setBooks((prev) => ({
...prev,
physics: e.target.value,
}))
}
For further actions, you may consider blocking this person and/or reporting abuse
Nico Prat -
Anwer Solangi -
Probir Sarkar -
Rowsan Ali -
Top comments (0)