This is my first React app. The goal is to click on as many icons as possible without duplicating a result. With 12 icons, the maximum score is 12. The app stores high scores from your session, but the data does not persist and is not saved.
The main components I used were the header and the icon. I took stats from each character, imported the json array, and created icons using the .map function to pass the props to the Component.
The app’s tracked state includes the Icon component (whether “clicked” is true or false for each element), the current score, the high score, and the message (which will change from “Click A Veggie!” to “GAME OVER!”).