{"id":44692006,"url":"https://github.com/andreafspeziale/beyhub","last_synced_at":"2026-02-15T07:30:37.605Z","repository":{"id":331714361,"uuid":"1128437775","full_name":"andreafspeziale/beyhub","owner":"andreafspeziale","description":"Completely vibe-coded beyblade web application 🌀","archived":false,"fork":false,"pushed_at":"2026-01-24T14:54:39.000Z","size":25036,"stargazers_count":2,"open_issues_count":2,"forks_count":0,"subscribers_count":0,"default_branch":"develop","last_synced_at":"2026-01-25T02:50:35.643Z","etag":null,"topics":["beyblade","bun","react","typescript","vibe-coding","vite","vitest","webapp"],"latest_commit_sha":null,"homepage":"https://beyhub.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/andreafspeziale.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-01-05T16:28:24.000Z","updated_at":"2026-01-24T14:54:44.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/andreafspeziale/beyhub","commit_stats":null,"previous_names":["andreafspeziale/beyhub"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/andreafspeziale/beyhub","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andreafspeziale%2Fbeyhub","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andreafspeziale%2Fbeyhub/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andreafspeziale%2Fbeyhub/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andreafspeziale%2Fbeyhub/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/andreafspeziale","download_url":"https://codeload.github.com/andreafspeziale/beyhub/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/andreafspeziale%2Fbeyhub/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29472880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-15T06:58:05.414Z","status":"ssl_error","status_checked_at":"2026-02-15T06:58:05.085Z","response_time":118,"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":["beyblade","bun","react","typescript","vibe-coding","vite","vitest","webapp"],"created_at":"2026-02-15T07:30:37.023Z","updated_at":"2026-02-15T07:30:37.600Z","avatar_url":"https://github.com/andreafspeziale.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n  \u003cp\u003e\n    \u003cimg src=\"./readme_cover.png\" height=\"404\" alt=\"BeyHub Cover\"/\u003e\n  \u003c/p\u003e\n  \u003cp\u003e\n    A web application for comparing and compose beyblades.\u003cbr\u003e\n  \u003c/p\u003e\n\u003c/div\u003e\n\n## Overview\n\n\u003e [!IMPORTANT]\n\u003e Experimenting [vibe-coding](https://en.wikipedia.org/wiki/Vibe_coding). I never checked anything regarding the code\n\nBeyHub allows you to:\n- **Compare Beyblades**: Select two beyblades and compare their stats side-by-side\n- **View Win Probability**: See estimated win percentages based on stats\n- **Explore Stats**: View detailed blade, ratchet, and bit statistics\n- **Compose Beyblades**: Create custom beyblade combinations from available components\n\n### Key Features\n- Search-based beyblade selection with autocomplete (`Cmd+K` to open)\n- Side-by-side stat comparison with visual bars\n- Custom beyblade composition with strategy presets (balanced, attack, defense, stamina)\n- Light/Dark theme toggle (`Cmd+D` to switch)\n- Mobile-responsive design\n- Expandable component details (Blade, Ratchet, Bit stats)\n\n## Prerequisites\n\n- **Bun** \u003e= 1.x (latest LTS recommended)\n- **Git**\n\n## Getting Started\n\n### Installation\n\n1. Clone the repository:\n   ```bash\n   git clone https://github.com/andreafspeziale/beyhub.git\n   cd beyhub\n   ```\n\n2. Install dependencies:\n   ```bash\n   bun install\n   ```\n\n3. Start the development server:\n   ```bash\n   bun run dev\n   ```\n\n4. Open your browser and navigate to `http://localhost:5173`\n\n## Available Scripts\n\n| Script | Description |\n|--------|-------------|\n| `bun run dev` | Start development server with hot reload |\n| `bun run build` | Build for production |\n| `bun run preview` | Preview production build locally |\n| `bun run lint` | Run Biome linter |\n| `bun run format` | Format code with Biome |\n| `bun run check` | Run linter and formatter checks (used in pre-commit) |\n| `bun test` | Run unit tests with Vitest |\n| `bun run test:coverage` | Run tests with coverage report |\n\n## Project Structure\n\n```\nbeyhub/\n├── public/\n│   ├── assets/beyblades/    # Beyblade images\n│   └── data/\n│       └── beyblades.json   # Beyblade data\n├── src/\n│   ├── components/          # React components\n│   │   ├── comparison/      # Comparison feature components\n│   │   ├── compose/         # Compose feature components\n│   │   ├── error/           # Error boundaries\n│   │   ├── layout/          # Layout components (Header, Nav, ThemeToggle)\n│   │   └── ui/              # shadcn/ui components\n│   ├── hooks/               # Custom React hooks\n│   ├── pages/               # Page components\n│   ├── schemas/             # Zod validation schemas\n│   ├── types/               # TypeScript types\n│   ├── utils/               # Utility functions\n│   └── App.tsx              # Main app component\n```\n\n## Beyblade Data\n\n### JSON Structure\n\nBeyblades are stored in `/public/data/beyblades.json`:\n\n```json\n{\n  \"beyblades\": [\n    {\n      \"id\": \"impact_drake_9_60LR\",\n      \"name\": \"Impact Drake 9-60LR\",\n      \"type\": \"Attack\",\n      \"bladeName\": \"Impact Drake\",\n      \"ratchetName\": \"9-60\",\n      \"bitName\": \"LR\",\n      \"blade\": {\n        \"attack\": 75,\n        \"defense\": 25,\n        \"stamina\": 10\n      },\n      \"ratchet\": {\n        \"attack\": 13,\n        \"defense\": 10,\n        \"stamina\": 7,\n        \"height\": 60\n      },\n      \"bit\": {\n        \"attack\": 45,\n        \"defense\": 5,\n        \"stamina\": 15,\n        \"dash\": 35,\n        \"burst\": 80\n      },\n      \"image\": \"/assets/beyblades/impact_drake_9_60LR.png\"\n    }\n  ]\n}\n```\n\n### Adding New Beyblades\n\n**Via Pull Request (Recommended):**\n\n1. Fork the repository\n2. Add entry to `public/data/beyblades.json` following the structure above\n3. Use snake_case for `id` (e.g., `beyblade_name_parts`)\n4. Provide all required stats as integers\n5. Add image to `/public/assets/beyblades/` or use placeholder URL\n6. Submit PR with clear description and source for stats\n7. Data validation runs automatically on app startup\n\n## Development Workflow\n\n### Code Quality\n\nThis project uses strict code quality tools:\n\n- **Biome**: Linting and formatting\n  - Import sorting by type\n  - Single quotes, semicolons required\n  - Line length: 100 characters\n- **TypeScript**: Strict mode, no `any` types allowed\n- **Husky**: Git hooks for automated checks\n\n### Making Changes\n\n1. Create a new branch:\n   ```bash\n   git checkout -b feat/your-feature-name\n   ```\n\n2. Make your changes following the code style\n\n3. Run checks before committing:\n   ```bash\n   bun run check\n   ```\n\n4. Commit using conventional commit format:\n   ```bash\n   git commit -m \"feat(scope): description\"\n   ```\n\n### Commit Convention\n\nFormat: `type(scope): description`\n\n**Types:**\n- `feat`: New feature\n- `fix`: Bug fix\n- `docs`: Documentation changes\n- `style`: Code style changes\n- `refactor`: Code refactoring\n- `test`: Test changes\n- `chore`: Maintenance tasks\n\n**Examples:**\n```bash\ngit commit -m \"feat(comparison): add win probability calculation\"\ngit commit -m \"fix(search): correct fuzzy matching logic\"\ngit commit -m \"docs(readme): update installation instructions\"\n```\n\n### Pre-commit Hooks\n\nHusky automatically runs:\n- Biome linter on staged files\n- Biome formatter on staged files\n- Commit message validation (commitlint)\n\nIf checks fail, fix the issues and commit again.\n\n## Testing\n\n### Running Tests\n\n```bash\n# Run all tests\nbun test\n\n# Run tests in watch mode\nbun test --watch\n\n# Run with coverage\nbun test --coverage\n```\n\n### Test Coverage\n\nUnit tests cover:\n- Win probability calculations\n- Stat aggregation functions\n- Search/filter functionality\n\nTests are located in `__tests__` directories alongside source files.\n\n## Tech Stack\n\n- **Runtime**: Bun\n- **Framework**: React 19 + TypeScript\n- **Build Tool**: Vite\n- **Styling**: Tailwind CSS v4 + shadcn/ui\n- **Validation**: Zod\n- **Linting/Formatting**: Biome\n- **Testing**: Vitest\n\n## Stay in touch\n\n- Author - [Andrea Francesco Speziale](https://x.com/andreafspeziale)\n- Beyblade Community - [Beyblade Wiki](https://beyblade.fandom.com/wiki/Beyblade_Wiki)\n\n## License\n\nBeyHub is [MIT licensed](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandreafspeziale%2Fbeyhub","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandreafspeziale%2Fbeyhub","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandreafspeziale%2Fbeyhub/lists"}