How amar-spe/e-waste works
E-Waste is a website for learning about recycling electronics and submitting a recycling cart. Its clearest transactional workflow is a visitor adding items and quantities in the browser, submitting them to the Express server, and having the server store an address and items in MySQL. The repository also includes login/signup handlers, informational pages, dashboard charts, and a location finder. Source excerpts show the server routes and client-side behavior, but not the EJS templates, so links between particular pages and scripts are not asserted.
Main entry points: index.js Express routes · cart.js Cart form · service.js Recycler locator · views Page templates
Components 19
Web application
- Express routes
index.js - Page templates
views - Dashboard charts
public/main.js - Home chart
public/home.js
Accounts and data
- Login and signup
index.js - User database
index.js - Login interactions
public/login.js - Logout interactions
public/logout.js
Recycling features
- Cart form
public/cart.js - Cart database
index.js - Recycler locator
public/service.js - Recycler list
public/recyclers.js
Informational content
- News list
public/news.js - Contact form
public/contact.js - Landing interactions
public/index1.js - About interactions
public/about.js - Dashboard about
public/Dashabout.js
Other components
- Visitor
- Google Maps
Connections 9
- Visitor → Express routes: requests pages
index.js - Express routes → Page templates: renders pages
index.js - Visitor → Cart form: submits items
public/cart.js - Cart form → Express routes: posts cart
public/cart.js - Express routes → Cart database: writes address and items
index.js - Visitor → Login and signup: submits credentials
- Login and signup → User database: queries and inserts users
index.js - Visitor → Recycler locator: requests location
public/service.js - Recycler locator → Google Maps: opens search
public/service.js