Added funcaitonality to onSelectChange

This commit is contained in:
Ken Jannette
2018-04-18 16:14:54 -04:00
parent f7dd06e9a8
commit 3e7f683f5c
2 changed files with 7 additions and 2 deletions

View File

@@ -22,8 +22,13 @@ class BooksApp extends React.Component {
}
onSelectChange = (e) => {
const id = e.target.name
const shelf = e.target.value
console.log(id, shelf)
this.setState((prevState) => {
prevState.filter(name === book.id)
})
}
render() {