You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
State management is a mess. Few things I'd like to touch to simplify:
Separate state of Game Creation (all the options, that are actually in "App.state") from State of the Game played (which is a bit everywhere, there's a start in "App.state.game".
GameState is doing too many things: Simplify with one component in charge of saving the cards in one place, so we would have 3 subcomponents, each handling one place (MAIN, SIDE, JUNK). I doubt that we need to save the state of Pack as it's sent by the server at connection. We need also a component to save autopick / burn id of current pick. Then GameState could just be a HoC that just wrap all of it. It should also be renamed because it clashes with App.state, or ... merge App.state into a new subcomponent of GameState that handles game creation options. That would indicate future devs where they should put/get the data in future features.
Further Information
We could use Redux as a clean and standard way to handle state management across the app. Anybody has a better suggestion ?
The text was updated successfully, but these errors were encountered:
Detailed Description
State management is a mess. Few things I'd like to touch to simplify:
Separate state of Game Creation (all the options, that are actually in "App.state") from State of the Game played (which is a bit everywhere, there's a start in "App.state.game".
GameState is doing too many things: Simplify with one component in charge of saving the cards in one place, so we would have 3 subcomponents, each handling one place (MAIN, SIDE, JUNK). I doubt that we need to save the state of Pack as it's sent by the server at connection. We need also a component to save autopick / burn id of current pick. Then GameState could just be a HoC that just wrap all of it. It should also be renamed because it clashes with App.state, or ... merge App.state into a new subcomponent of GameState that handles game creation options. That would indicate future devs where they should put/get the data in future features.
Further Information
We could use Redux as a clean and standard way to handle state management across the app. Anybody has a better suggestion ?
The text was updated successfully, but these errors were encountered: