How ashvary1996/e-com-app works
This is a full-stack e-commerce application: shoppers browse products, manage a cart, check out and pay, then view orders and account details; administrators manage catalog, users, orders and dashboard analytics. The React client routes these experiences and calls an Express API, whose controllers coordinate authentication, commerce services, persistence and payment/email integrations. The tree and source index establish several unsampled product areas, but their internal calls are not inferred; dashed links mark likely client-to-API interactions where excerpts do not verify them.
Main entry points: AppRoutes.jsx Page routing · server.js Express application · api.js API client · models Commerce and user records
Components 22
Storefront
- Client shell
client/src/App.jsx - Page routing
client/src/routes/AppRoutes.jsx - Catalog browsing
client/src/pages/Products.jsx - Product details
client/src/pages/ProductDetails.jsx
Commerce
- Cart
client/src/pages/Cart.jsx - Checkout
client/src/pages/Checkout.jsx - Cart endpoints
server/controllers/cartController.js - Order workflow
server/controllers/orderController.js - Payment workflow
server/controllers/paymentController.js
Identity
- Account and orders
client/src/pages/account - Authentication pages
client/src/pages/auth - Authentication endpoints
server/controllers/authController.js - Session and auth logic
server/services/authService.js
Administration
- Admin console
client/src/pages/account/(admin) - Admin endpoints
server/controllers/adminController.js
API and persistence
- API client
client/src/services/api.js - Express application
server/server.js - Product endpoints
server/controllers/productController.js - Commerce and user records
server/models
Other components
- Shopper
- Razorpay
- Email provider
Connections 34
- Shopper → Client shell: uses
client/src/App.jsx - Client shell → Page routing: renders
client/src/App.jsx - Page routing → Catalog browsing: routes to
client/src/routes/AppRoutes.jsx - Page routing → Product details: routes to
client/src/routes/AppRoutes.jsx - Page routing → Cart: routes to
client/src/routes/AppRoutes.jsx - Page routing → Checkout: routes to
client/src/routes/AppRoutes.jsx - Page routing → Authentication pages: routes to
client/src/routes/AppRoutes.jsx - Page routing → Account and orders: routes to
client/src/routes/AppRoutes.jsx - Page routing → Admin console: routes to
client/src/routes/AppRoutes.jsx - Client shell → API client: requests
- Catalog browsing → API client: loads catalog
- Cart → API client: loads and updates
- Checkout → API client: submits checkout
- Authentication pages → API client: authenticates
- Account and orders → API client: requests account data
- Admin console → API client: manages store
- API client → Express application: calls API
- Express application → Product endpoints: mounts routes
server/server.js - Express application → Cart endpoints: mounts routes
server/server.js - Express application → Order workflow: mounts routes
server/server.js - Express application → Payment workflow: mounts routes
server/server.js - Express application → Authentication endpoints: mounts routes
server/server.js - Express application → Admin endpoints: mounts routes
server/server.js - Authentication endpoints → Session and auth logic: delegates to
server/controllers/authController.js - Authentication endpoints → Email provider: sends messages
server/controllers/authController.js - Payment workflow → Razorpay: creates payment
server/controllers/paymentController.js - Payment workflow → Email provider: sends confirmations
server/controllers/paymentController.js - Session and auth logic → Commerce and user records: reads and writes
server/services/authService.js - Authentication endpoints → Commerce and user records: accesses records
- Product endpoints → Commerce and user records: accesses records
- Cart endpoints → Commerce and user records: accesses records
- Order workflow → Commerce and user records: reads and writes
server/controllers/orderController.js - Payment workflow → Commerce and user records: reads and writes
server/controllers/paymentController.js - Admin endpoints → Commerce and user records: reads and writes
server/controllers/adminController.js