Another React Poker App Update
I made some good progress on the poker app the past couple of weeks, namely the ability to import hands via text string as well as a slider for adding/removing hands to the current displayed hand range:
I also added localStorage for saving a user's ranges locally. I haven't yet decided if I'm going to add a database and user registration, but I think I'll build out all the features I want first and then worry about the higher-level stuff.
React Poker App Update
I'm super excited that I was able to almost completely port my poker hand generator app to React from vanilla JavaScript over the past few days with some help from a more senior level dev friend. I have it about 90% complete, or at least as complete as it was in vanilla JavaScript and I'm learning a ton about React in the process.
My recent accomplishments:
- Got all of the buttons working as far switching the positions and situations the user wants to view. The toughest part was accounting for all the subSituations (for example: situation = "RFI vs 3B": you Raised First In and someone 3Bet, or re-raised you | position = "UTG": Under The Gun, or the person to the left of the Big Blind | subSituation = "vs UTG1": You are facing a re-raise from the person at UTG1, or 1 to the left of UTG)
- Created a second useState that contains only the current display of hands and actions (handState) - this allows the user to only save the actions to a specific scenario when they press the "Save" button. It also allows them to clear the handState.
Next steps:
- Duplicate the percentage calculations that update below the hand grid
- Allow the user to import or type in a string of hand ranges so the user doesn't have to click them all
- Save the data to localStorage and also to the local device, which would also allow the user to upload a file with saved stats so they don't lose them.
Looking forward to getting a live working version up.
0 Comments
Re-building the poker hand range generator in React
This past weekend one of my senior dev friends helped me get started in changing the poker range took I'm building (initially in vanilla JavaScript) over to React. As React is on my list of software-related tools that I want to get better at, I think this is a good opportunity to learn more about it while building the tool using a library that will allow more flexibility and functionality when I want to add things to the project in the future.
0 Comments
0 Comments