Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

As a user, I want to be able to see a stateful element dynamically render on the page. #2

Open
5 of 6 tasks
Fweddi opened this issue May 29, 2019 · 1 comment
Open
5 of 6 tasks
Assignees

Comments

@Fweddi
Copy link
Collaborator

Fweddi commented May 29, 2019

  • Add a state (and setState) function to store the user's 'energy' value
  • Render different stages of the 'energy bar' meter depending on the energy's state
  • Decrement the energy's state every unit of time (e.g. three seconds?)
  • The initial energy 'state' correlates with the amount of Github followers the user has
  • Once the energy's state is 'zero', the user can no longer give any more flowers
  • When both user's energy state is 'zero', the game ends
@Fweddi Fweddi added this to To do in Flower Power May 29, 2019
@Fweddi Fweddi mentioned this issue May 29, 2019
@Fweddi Fweddi moved this from To do to In progress in Flower Power May 30, 2019
@Fweddi
Copy link
Collaborator Author

Fweddi commented May 31, 2019

For the end of the game, we could render the page content dynamically with something like this?

return {time1 > 0 || time2 > 0 ? {game content} : <h1> "Game Over" </h1> }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Flower Power
  
In progress
Development

No branches or pull requests

2 participants