👉 LIVE PREVIEW 👈
This is a memory card game that consists of 7 phases. The user can click the cards that are displayed. Each time a card is clicked, the player will get one point added to their score. If the user clicks a card that was already clicked, the score will be reset to 0 and will be brought back to the beggining of the game (just like in old-school videogames :D). The best score of the user in the current session will be stored between games so it can challenge itself with getting the highest score possible, or who knows, maybe beating the game ;)
- Build a memory game of programming tools, languages and concepts
- Learn the usage of functional components
- Take my first steps with Typescript typing system
- Use of React hooks and learn their quirks and differences opposed to what the lifecycle methods do offer
- Defining interfaces for a given variable, parameters or function return values
- Setting up a project with React and Typescript
- Organize state to make sure all the rerenders are provided with the synced information of state
- React
- Typescript
- Jest
- Creating interfaces for my components props so they would get the types they expected. Looked up on the internet some tutorials.
- Setting up and using React with Typescript. It first felt super clunky but I ended up finding a good configuration.
- Manage the phase update everytime the user would reach the end of every phase. I had to rearrange my state to accomplish this.
Styling could be improved Add localStorage functionality or database to store the highest score among users Usage of some Hooks to avoid repeating code and make it look cleaner