Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/snelsi/poker

♠️ Poker Game
https://github.com/snelsi/poker

game hooks poker poker-game react styled-components typescript

Last synced: about 2 months ago
JSON representation

♠️ Poker Game

Awesome Lists containing this project

README

        

![App shot](https://github.com/snelsi/poker/blob/master/public/shot.jpg)

# Poker Game

https://poker.snelsi.now.sh/

This is my technical assignment on the Middle Frontend developer offer on 'Poker' theme. Interpretation of the theme came out, maybe, not quite accurate, but whatever. In the end, I even overdid all tasks in it.

# Tasks:

1. Clicking the button should generate two random hands with cards in memory (console.log).
2. Clicking the button should render two random hands on the page as cards.
3. Determine the winning hand by its number of pairs, add class="winning" to hand.
4. Determine winning pairs and add class="pair0" (or "pair1" for 2nd pair) to cards.
5. [Extra Credit] Ensure that 90% of hands have at least one pair

All main logic is contained inside 'usePoker', 'useCombinations' and 'useRank' hooks.
Made with React/Typescript and Styled Components.

This project is not optimized for mobile devices yet.

@ 2020