Merge pull request #41 from samuel-rey/notyping
Fixes #40 - Prevent typing after winning game
This commit is contained in:
commit
00630b24bd
1 changed files with 1 additions and 1 deletions
|
@ -50,7 +50,7 @@ function App() {
|
|||
}, [isGameWon])
|
||||
|
||||
const onChar = (value: string) => {
|
||||
if (currentGuess.length < 5 && guesses.length < 6) {
|
||||
if (currentGuess.length < 5 && guesses.length < 6 && !isGameWon) {
|
||||
setCurrentGuess(`${currentGuess}${value}`)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue