SitePoint
  • Premium
  • Library
  • Community
  • Jobs
  • Blog
LoginStart Free Trial
Advanced React with TypeScript
React RPS Intro
Initial Setup
Score and Results
Choose and Play
Adding Context API
Retrieving Values From Context
Initial State Context
Creating ScoreReducer
Creating ScoreReducer
Playerhand Active Class
Test Setup with Vitest
Testing ScoreReducer
Testing Hand Selection
Testing Options Context
Generate Computer Random Option
Add Computer Option to Context
Countdown Timer
Testing Countdown Timer
Player and Computer Score
Checking The Winner
Update ScoreReducer with Winner
Display Score Results
Testing Display Score Results
Playing Hand Shake
Winner Animation
Testing Winner Animation
Reset The Game
Tests Coverage