How allencodess/huntleys-website works
Huntley’s Sauces is a full-stack storefront whose main journey is product discovery, cart management, authenticated shipping and payment, order creation, and order history. Admins additionally manage products, orders, and users; shoppers can contact the business. The graph combines documented capabilities with visible source references. Several route handlers, checkout screens, and integrations were not excerpted, so their links are cited to the README rather than presented as inspected call chains.
Main entry points: App.jsx Web app routing · routes API routes · models MongoDB models · ProductDetails.jsx Product details
Components 27
Storefront
- Web app routing
frontend/src/App.jsx - Product browsing
frontend/src/Screens/Products.jsx - Product details
frontend/src/Screens/ProductDetails.jsx - Product API client
frontend/src/slices/productApiSlice.js - Contact form
frontend/src/components/ContactForm.jsx
Commerce
- Persistent cart
frontend/src/slices/cartSlice.js - Checkout steps
frontend/src/Screens/Shipping.jsx - Payment screen
frontend/src/Screens/PaymentScreen.jsx - PayPal payments
- Order history
frontend/src/Screens/OrderScreen.jsx - Order API client
frontend/src/slices/ordersApiSlice.js
Identity & Admin
- Account screens
frontend/src/Screens/Login.jsx - Authentication state
frontend/src/slices/authSlice.js - User API client
frontend/src/slices/usersApiSlice.js - Admin dashboard
frontend/src/Screens/admin/ProductEditScreen.jsx
Backend Platform
- Express API server
backend/server.js - API routes
backend/routes - Product operations
backend/controllers/productController.js - User operations
backend/controllers/userController.js - Order operations
backend/controllers/orderController.js - Authentication guard
backend/middleware/authMiddleware.js - MongoDB models
backend/models - Image upload
backend/routes/uploadRoutes.js
Other components
- Shopper
- MongoDB
- Cloudinary
- Transactional email
Connections 31
- Shopper → Web app routing: visits
- Web app routing → Product browsing: routes to
frontend/src/App.jsx - Web app routing → Product details: routes to
frontend/src/App.jsx - Product details → Product API client: requests products
frontend/src/Screens/ProductDetails.jsx - Product details → Persistent cart: adds items
frontend/src/Screens/ProductDetails.jsx - Shopper → Persistent cart: manages items
- Web app routing → Checkout steps: routes to
frontend/src/App.jsx - Checkout steps → Payment screen: continues checkout
- Payment screen → PayPal payments: pays with
- Payment screen → Persistent cart: reads cart
frontend/src/Screens/PaymentScreen.jsx - Web app routing → Order history: routes to
frontend/src/App.jsx - Order history → Order API client: requests orders
frontend/src/Screens/OrderScreen.jsx - Web app routing → Account screens: routes to
frontend/src/App.jsx - Account screens → User API client: calls account API
frontend/src/Screens/Login.jsx - Account screens → Authentication state: sets credentials
frontend/src/Screens/Login.jsx - Web app routing → Admin dashboard: routes to
frontend/src/App.jsx - Admin dashboard → Product API client: manages products
frontend/src/Screens/admin/ProductEditScreen.jsx - Express API server → API routes: mounts routes
backend/server.js - API routes → Product operations: dispatches product requests
backend/routes/productRoutes.js - API routes → User operations: dispatches user requests
backend/routes/userRoutes.js - API routes → Order operations: dispatches order requests
backend/routes/orderRoutes.js - API routes → Authentication guard: protects endpoints
backend/routes/orderRoutes.js - Product operations → MongoDB models: reads and writes
backend/controllers/productController.js - User operations → MongoDB models: reads and writes
backend/controllers/userController.js - Order operations → MongoDB models: reads and writes
backend/controllers/orderController.js - Authentication guard → MongoDB models: loads user
backend/middleware/authMiddleware.js - MongoDB models → MongoDB: persists records
- API routes → Image upload: exposes upload endpoint
backend/server.js - Image upload → Cloudinary: stores images
backend/routes/uploadRoutes.js - Shopper → Contact form: submits inquiry
- Contact form → Transactional email: delivers message