Frontend take-home · 180 minutes
Product list from a REST API
Build a product list page in React with TypeScript in three hours. The data comes from a mock REST API with about 100 products. You set it up yourself, for example with a small JSON server or a library that mocks requests. The page has a search box, filters by category and price range, sorting and pagination. The search, the filters, the sort and the page are kept in the URL, so a reload or a shared link shows the same view. The page shows loading, error and empty states. Write tests for the main behavior, and a README that explains your decisions.
Requirements
- The list shows name, price, category and image for each product, loaded with GET requests from the mock API
- Search by name with a debounced input, filters by category and price range, and sorting by price and by name
- Pagination with a fixed page size, and the total number of results on screen
- Search, filters, sort and page are in the URL and are restored on load; Back and Forward work
- The list has a loading state, an error state with Retry, and an empty state
- A new search or filter returns to page 1, and a late response never replaces a newer one
- Tests cover the main behavior, with the network mocked
- A README with the run steps and your decisions
What reviewers look for
What reviewers look for, the checklist and the stretch goals opens with a year in the app. What a year includes