{"id":20779940,"url":"https://github.com/devklick/basic-blackjack","last_synced_at":"2026-01-26T13:04:04.712Z","repository":{"id":45414265,"uuid":"435036327","full_name":"devklick/basic-blackjack","owner":"devklick","description":"An overly-simplified version of the Blackjack card game","archived":false,"fork":false,"pushed_at":"2024-08-07T19:57:19.000Z","size":3219,"stargazers_count":2,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-03T05:36:15.271Z","etag":null,"topics":["casino-games","classic-game","electron","game","react"],"latest_commit_sha":null,"homepage":"https://devklick.github.io/basic-blackjack/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/devklick.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-12-05T00:06:41.000Z","updated_at":"2024-04-19T07:47:30.000Z","dependencies_parsed_at":"2024-08-07T22:18:49.469Z","dependency_job_id":null,"html_url":"https://github.com/devklick/basic-blackjack","commit_stats":null,"previous_names":[],"tags_count":32,"template":false,"template_full_name":null,"purl":"pkg:github/devklick/basic-blackjack","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devklick%2Fbasic-blackjack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devklick%2Fbasic-blackjack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devklick%2Fbasic-blackjack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devklick%2Fbasic-blackjack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/devklick","download_url":"https://codeload.github.com/devklick/basic-blackjack/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/devklick%2Fbasic-blackjack/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28778747,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-26T11:46:04.308Z","status":"ssl_error","status_checked_at":"2026-01-26T11:46:02.664Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["casino-games","classic-game","electron","game","react"],"created_at":"2024-11-17T13:30:52.886Z","updated_at":"2026-01-26T13:04:04.678Z","avatar_url":"https://github.com/devklick.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Blackjack (but not really)\n\nThis is an over-simplified, crude version of Blackjack.\nIt's actually more along the lines of the classic card games Twenty-One or Pontoon,\nbut doesnt really follow the rules of any one of these games.\n\n\n\u003cdetails\u003e\n\u003csummary\u003eClick to see screenshots!\u003c/summary\u003e\u003e\n\n![Initial Round](/docs/InitialRound.png)\n![Dealer Bust](/docs/DealerBust.png)\n![Five Card Trick](/docs/FiveCardTrick.png)\n![Confirm *stick*](/docs/ConfirmStick.png)\n![Confirm *hit*](/docs/ConfirmHit.png)\n\u003c/details\u003e\n\u003cdetails\u003e\n\u003csummary\u003eClick to see gameplay!\u003c/summary\u003e\n\n![Confirm *hit*](/docs/Gameplay.gif)\n\u003c/details\u003e\n\n---\n\n## Play the game\nYou can play the game directly in your browser or download the desktop app for your operating system. \n\n### Browser\nhttps://devklick.github.io/basic-blackjack/\n\n### Desktop\nDownload the relevant installer from the [releases page](https://github.com/devklick/basic-blackjack/releases).\nNote that at this time, only Windows and Linux operating systems are supported.\nNote that the installers are not currently signed and likely never will be. Your operating system will likely throw up all sorts of warnigs and installing an unknown application. The risk is yours.\n\n---\n## Working with the repo\nThis game is a React app packaged as a desktop app using Electron. To run the react app, simply run `npm start`. To run the desktop app, run `npm dev`. To run the tests, write them first.\n\n---\n## Objective\nThe idea is to end up with between 2 and 5 cards who's rank total 21 or less. The winner will be determined based on the hand rank, the numer of cards in the hand, and the highest card. See the [Ways to win](#ways-to-win) section.\n\n---\n## Overview\nThe game contains two players; the player (you) and the dealer (computer). The dealer will start by dealing four cards:\n\n1. Deal 1 card to player, facing up\n2. Deal 1 card to dealer, facing up\n3. Deal 1 card to player, facing up\n4. Deal 1 card to dealer, facing *down*\n\n### Player Round\nThe player will then have a chance to decide whether they want to *hit* (receive another card, face up) or *stick* (stick with their current cards). If they decide to *hit*, their cards will either total 21 or less, in which case they get to decide whether to *hit* or *stick* again (up to a total of 3 times), or they will be **bust** (their cards total exceed 21), in which case they loose and the dealer automatically wins.\n### Dealer Round\nIf the player decides to *stick*, it's over to the dealer (computer). First, their second card, which was facing down until this point, will be turned face up. The dealer (computer) then decides whether they want to *hit* or *stick*, just like the player. The only differences are that:\n\n- The dealer must *hit* if their score is less than 16\n- The dealer must *hit* if their score is less than the players score\n\n### Result\nAt the end of the dealers round, either the player or dealer will have won. \n\n---\n\n## \u003ca name=\"WaysToWin\"\u003e\u003c/a\u003e Ways to win\nThere's a few ways in which a result is reached:\n\n### As cards are dealt:\n\n- Player's hand exceeds 21, dealer automatically wins (or vis versa)\n- Player's hand is less than or equal to 21 and contains 5 cards, winner automatically wins (or vis versa)\n\n### After player and dealer have decided to *stick*:\n- Player's hand value exceeds dealers hand value, player wins (or vis versa)\n- Player's hand value and dealers hand value are the same but player has more cards, player wins (or vis versa)\n- Player's hand value and dealers hand value are the same and both have the same number of cards, but player has a higher card, player wins (or vis versa)\n- Player's hand value and dealers hand value are the same and both have the same number of cards and neither has a highest card, game reaches a draw.\n\n---\n\n## Sanity Checks\nSelecting *stick* when your hand totals 10 or less will cause a popup to will appear asking to if you're sure you want to *stick* with your current score. You can select *yes* or *no*.\n\nLikewise, selecting *hit* when your hand totals 18 or more will cause the same popup to appear, asking if you're sure you want another card. You can select *yes* or *no*.\n\n---\n\n## Score Tracking\nThe \"current best hand score\" is updated every time a card is dealt. As an Ace can be treated as a 1 or 11, the relevant value is selected to get the hand as close to 21 as possible without exceeding it. \n\nThe total wins are also tracked, so you will see how many times the dealer has whooped your ass (at least in my case). This information is not preserved between screen refreshes.\n\n---\n\n## Possible Future Enhancements\n- [x] Improve card dealing animation (delay between each card being dealt).\n- [x] Have an option to disable popups entirely.\n- [x] Store total wins (history) in cache so it's preserved between refreshes.\n- [ ] Introduce betting.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevklick%2Fbasic-blackjack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdevklick%2Fbasic-blackjack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdevklick%2Fbasic-blackjack/lists"}