# React Learning Dashboard with Search & Status

TechBuilt Open School — Free, self-guided technical project kit

- **Track:** Frontend Engineering
- **Level:** Intermediate
- **Access:** No account, signup, payment or enrollment required
- **Format:** Guided plan and runnable starter example, not a complete solution or a live class
- **Online guide:** https://techbuiltos.online/projects/react-learning-dashboard

## Project goal

Practice components, state, accessible filtering and progressively stronger data-state management.

Build a React dashboard that filters course cards and handles loading, empty and error states before connecting a real API.

## Before you begin

- Node.js and npm installed
- React component/props basics and JavaScript array methods

## Local setup

1. Create a React + Vite project using npm create vite@latest, select the React template.
2. Replace App.jsx with the starter component and start the development server.
3. Build the UI using local sample records first; the next milestone is API integration.

## Starter example — App.jsx

The sample below is a starting point. It may require the prerequisites above. Complete the subsequent milestones to finish your own project.

```jsx
import { useState } from "react";

const lessons = [
  { id: 1, title: "HTML Foundations", status: "Completed" },
  { id: 2, title: "React Components", status: "In progress" },
  { id: 3, title: "REST APIs", status: "Not started" },
];

export default function App() {
  const [query, setQuery] = useState("");
  const visible = lessons.filter((item) =>
    item.title.toLowerCase().includes(query.trim().toLowerCase())
  );
  return (
    <main>
      <h1>Learning dashboard</h1>
      <label htmlFor="course-search">Search lessons</label>
      <input id="course-search" value={query} onChange={(e) => setQuery(e.target.value)} />
      {visible.length === 0 ? <p>No matching lessons.</p> : (
        <ul>{visible.map((item) =>
          <li key={item.id}><strong>{item.title}</strong> — {item.status}</li>
        )}</ul>
      )}
    </main>
  );
}
```

## Build milestones

1. Split a card and search form into reusable components.
2. Filter the list without mutating source data and show a meaningful empty state.
3. Add a mock asynchronous fetch with loading, success and failure views.
4. Connect a suitable public or local practice API only when you can verify its response shape.
5. Write tests for search behavior and an accessible form label.

## Completion checklist

- [ ] Typing a query filters titles case-insensitively.
- [ ] An unmatched query displays an empty-state explanation.
- [ ] Loading and API error states do not leave a blank screen.
- [ ] Cards have stable React keys and input has an associated label.

## Optional extensions

- Add a course progress chart based on completed lesson counts.
- Write an integration test for a failed API response and retry flow.

## Related learning

- Individual course roadmap: https://techbuiltos.online/courses/react
- Individual course roadmap: https://techbuiltos.online/courses/javascript
- Individual course roadmap: https://techbuiltos.online/courses/rest-apis

- Specialization: https://techbuiltos.online/specializations/frontend-developer
- Specialization: https://techbuiltos.online/specializations/full-stack-developer

---

This original self-study project is independent of paid cohorts. Review any external library documentation before use. Do not commit real credentials, private client files or personal data to public repositories.
