Skip to content

Commit

Permalink
Avoid line jump
Browse files Browse the repository at this point in the history
  • Loading branch information
afontcu committed Dec 23, 2021
1 parent 86a04ab commit 394c238
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
],
"author": {
"name": "Adrià Fontcuberta",
"url": "https://twitter.com/afontcu_"
"url": "https://twitter.com/afontq"
},
"main": "src/index.js",
"dependencies": {
Expand Down
4 changes: 2 additions & 2 deletions src/components/GameContainer.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class GameContainer extends React.Component {
handleFirstLetter = () => {
const startTime = Date.now()

this.setState({ msg: 'Run Forrest, run!' })
this.setState({ msg: 'Run Forrest!\nRun!' })

this.interval = setInterval(() => {
const elapsedTime = Date.now() - startTime
Expand All @@ -69,7 +69,7 @@ class GameContainer extends React.Component {
}

handleNextLetter = () => {
this.setState(prevState => ({
this.setState((prevState) => ({
currentPosition: prevState.currentPosition + 1,
letterHue: huesList[prevState.currentPosition % huesList.length],
}))
Expand Down

0 comments on commit 394c238

Please sign in to comment.