{"id":26722542,"url":"https://github.com/darshanas17/coin-toss-game-react","last_synced_at":"2026-04-17T08:31:05.805Z","repository":{"id":284474287,"uuid":"955061848","full_name":"Darshanas17/Coin-Toss-Game-React","owner":"Darshanas17","description":"A simple and interactive React.js game where users can flip a virtual coin and track results dynamically. The game features random toss outcomes, real-time scoreboard updates, and a clean UI. 🚀","archived":false,"fork":false,"pushed_at":"2025-03-26T03:49:53.000Z","size":0,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-26T04:35:16.246Z","etag":null,"topics":["css","es6-modules","game","html","javascript","reactsjs","state-management"],"latest_commit_sha":null,"homepage":"https://darshanas17.github.io/Coin-Toss-Game-React/","language":"JavaScript","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/Darshanas17.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2025-03-26T03:40:59.000Z","updated_at":"2025-03-26T03:49:56.000Z","dependencies_parsed_at":"2025-03-26T04:35:22.275Z","dependency_job_id":"12a7641b-d08c-4dd8-9693-c494d1ab145c","html_url":"https://github.com/Darshanas17/Coin-Toss-Game-React","commit_stats":null,"previous_names":["darshanas17/coin-toss-game-react"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Darshanas17%2FCoin-Toss-Game-React","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Darshanas17%2FCoin-Toss-Game-React/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Darshanas17%2FCoin-Toss-Game-React/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Darshanas17%2FCoin-Toss-Game-React/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Darshanas17","download_url":"https://codeload.github.com/Darshanas17/Coin-Toss-Game-React/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245918528,"owners_count":20693721,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["css","es6-modules","game","html","javascript","reactsjs","state-management"],"created_at":"2025-03-27T20:26:22.351Z","updated_at":"2026-04-17T08:31:05.748Z","avatar_url":"https://github.com/Darshanas17.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Coin Toss Game\n\nA fun and interactive **Coin Toss Game** built using React.js, where users can toss a virtual coin and track the results.\n\n## 🚀 Live Demo\n[Click Here to View the Game](https://darshanas17.github.io/Coin-Toss-Game-React/)\n\n## 📸 Preview\n\n![Coin Toss Game Output](https://assets.ccbp.in/frontend/content/react-js/coin-toss-game-output.gif)\n\n---\n\n## 🎯 Features\n\n- **Coin Toss Simulation:** Click the \"Toss Coin\" button to flip the coin\n- **Random Toss Result:** Uses JavaScript's `Math.random()` to determine heads or tails\n- **Scoreboard:** Tracks the total number of tosses, heads, and tails count\n- **Dynamic Image Update:** Displays the respective coin image based on toss results\n\n---\n\n## 🛠️ Installation \u0026 Setup\n\n1. Clone the repository:\n   ```sh\n   git clone https://github.com/Darshanas17/Coin-Toss-Game-React.git\n   cd coin-toss-game\n   ```\n2. Install dependencies:\n   ```sh\n   npm install\n   ```\n3. Run the application:\n   ```sh\n   npm start\n   ```\n\n---\n\n## 📝 Implementation Details\n\n### **Technologies Used**\n\n- React.js\n- CSS (for styling)\n- JavaScript (ES6+)\n\n### **File Structure**\n\n```\n├── src\n│   ├── components\n│   │   ├── CoinToss\n│   │   │   ├── index.js\n│   │   │   ├── index.css\n│   ├── App.js\n│   ├── index.js\n├── package.json\n```\n\n---\n\n## 🎮 How to Play?\n\n1. Click on the **Toss Coin** button\n2. The app randomly determines whether it's **Heads** or **Tails**\n3. The corresponding coin image appears\n4. The **Heads, Tails, and Total Counts** are updated dynamically\n\n---\n\n## 📂 Resources\n\n### **Colors Used**\n\n- `#e2a139` (Gold)\n- `#f9d423` (Bright Yellow)\n- `#ffffff` (White)\n- `#a35200` (Dark Orange)\n- `#334155` (Grayish Blue)\n- `#475569` (Dark Blue Gray)\n\n---\n\n## 📜 License\n\nThis project is licensed under the **MIT License**.\n\n---\n\n## 🤝 Contributing\n\nFeel free to fork and contribute to this project.\n\n1. Fork the repository\n2. Create a new branch (`feature/your-feature`)\n3. Commit your changes\n4. Push to the branch\n5. Open a Pull Request\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarshanas17%2Fcoin-toss-game-react","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdarshanas17%2Fcoin-toss-game-react","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarshanas17%2Fcoin-toss-game-react/lists"}