Let's use what we learned about event handlers in React to complete this app.
-
Use
showAnswer
as a callback function to make the answer to the first joke appear in the console when the user clicks the first button. -
Use state to to make the answer to the second joke appear when the user clicks the second button.
- Note: The answer is "carrot"...haha.
- Hint: You will need to use the state setter function
setJokeAnswer
.