How sanketh149/secondserve works
SecondServe is a browser-only food-rescue demo. Donors enter food details, review suggestions, plan recipients, and start offers; recipients respond and confirm actual quantities received, which drive displayed impact. The React routes and shared in-memory store support this demo workflow. The README describes additional locked product capabilities and planned services, but the frontend does not connect to production authentication, AI, routing, or backend systems; those integrations are not shown as live components.
Main entry points: App.tsx Route application · DonorPages.tsx Donor pages · RecipientPages.tsx Recipient pages · demo-context.ts Store context
Components 16
Application navigation
- React bootstrap
frontend/src/main.tsx - Route application
frontend/src/App.tsx - Role entry
frontend/src/pages/RoleEntryPage.tsx - Role workspaces
frontend/src/components/AppShell.tsx
Donor rescue workflow
- Donor pages
frontend/src/pages/DonorPages.tsx - Food Passport
frontend/src/pages/DonorPages.tsx - Readiness and planning
frontend/src/pages/DonorPages.tsx - Split the Batch
frontend/src/pages/DonorPages.tsx
Recipient handoff
- Recipient pages
frontend/src/pages/RecipientPages.tsx - Offer response
frontend/src/pages/RecipientPages.tsx - Confirmed receipt
frontend/src/pages/RecipientPages.tsx - Impact views
frontend/src/pages/RecipientPages.tsx
Demo state
- Store context
frontend/src/lib/demo-context.ts - In-memory workflow state
frontend/src/lib/demo-store.tsx - Synthetic seed data
frontend/src/lib/demo-data.ts
Other components
- Demo participant
Connections 18
- Demo participant → React bootstrap: opens demo
README.md - React bootstrap → Route application: renders
frontend/src/main.tsx - Route application → Role entry: routes to
frontend/src/App.tsx - Route application → Role workspaces: routes through
frontend/src/App.tsx - Route application → Donor pages: routes to
frontend/src/App.tsx - Route application → Recipient pages: routes to
frontend/src/App.tsx - Route application → In-memory workflow state: provides state
frontend/src/App.tsx - Donor pages → Store context: reads and updates
frontend/src/pages/DonorPages.tsx - Recipient pages → Offer response: renders
frontend/src/pages/RecipientPages.tsx - Recipient pages → Confirmed receipt: confirms quantity
frontend/src/pages/RecipientPages.tsx - Recipient pages → Impact views: shows totals
frontend/src/pages/RecipientPages.tsx - Store context → In-memory workflow state: accesses context
frontend/src/lib/demo-context.ts - In-memory workflow state → Synthetic seed data: initializes from
frontend/src/lib/demo-store.tsx - Donor pages → Food Passport: collects details
frontend/src/pages/DonorPages.tsx - Donor pages → Readiness and planning: reviews rescue plan
README.md - Donor pages → Split the Batch: plans allocation
README.md - Offer response → Store context: responds through
- Confirmed receipt → Store context: submits receipt through