Feature: save restaurants to a favorites list
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 2h 19m
- Merged PRs (30d)
- 30
Description
## Summary
Users have no way to bookmark a restaurant to come back to. The profile page already has a tab structure (`UserPage/index.tsx`, "Reviews" / "Businesses") that a third "Saved" tab fits naturally.
## Proposal
- `favorites` table (user_id, restaurant_id, unique together, created_at).
- `POST` and `DELETE /api/restaurants//favorite`, `GET /api/users//favorites`; an `is_favorited` flag in restaurant payloads when logged in.
- Heart toggle on the `Restaurant` card and the `SingleRestaurant` header; a "Saved" tab on the profile (decide whether it is public or own-profile only).
- Optional: a saved-count on the restaurant detail page.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with UserPage/index.tsx and the existing Restaurant and SingleRestaurant entry points, then trace the restaurant and user API patterns. Define the favorites table and the POST, DELETE, and GET endpoints, including the logged-in is_favorited behavior. Done means users can toggle favorites, view them in a Saved profile tab, and the profile visibility decision is documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, database, full-stack
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100