A React + TypeScript project focused on learning by fixing broken components. Each challenge presents a buggy React component along with instructions. Your goal is to analyze, refactor, and fix the logic so the component behaves correctly.
├── src
│ ├── challenges # Broken challenge components
│ ├── components # Reusable UI components
│ ├── data # Challenges configuration
│ ├── pages # App pages (Home, Challenge)
│ ├── App.tsx # Routes definition
│ └── main.tsx # App entry point
src/challenges : Contains broken components users must fix
src/data/challenges.ts : Central registry of all challenges.
This project is designed as a learning platform for React developers. It focuses on common real-world mistakes such as shared state, improper component reuse, and logic duplication.
The goal is not just to "make it work", but to encourage:
- Reading and understanding existing code
- Debugging broken logic
- Refactoring towards better patterns
1- Clone the repository
git clone https://github.com/DiegoLSdev/Code-Tests.git
cd Code-Tests
2- Install dependencies
npm install
3- Run the project
npm run dev
The app will be available at:
http://localhost:5173
-
Open a challenge from the Home page
-
Read the instructions carefully
-
Navigate to the corresponding file in src/challenges/
-
Fix the broken logic
-
Reload and verify correct behavior
-
There are no automatic tests (yet). You validate solutions by behavior.
-
Create a new component in src/challenges/
-
Add broken logic + instructions as comments
-
Register it in src/data/challenges.ts
Contributions are welcome!
You can help by:
- Adding new challenges
- Improving existing challenges
- Fixing bugs or improving UI
- Improving documentation