How dinada04/toyhaven works
Toy Haven is a browser-based toy storefront with product browsing, cart and wishlist management, checkout, and feedback. Its main workflow is browsing products, adding items to a cart, reviewing totals, and submitting checkout details; wishlist, newsletter, FAQ, and promotional features supplement that path. Most behavior is implemented in the shared script.js, with a service worker caching site files for offline access. The excerpts do not show page-to-script wiring or the full checkout implementation, so those links are omitted.
Main entry points: script.js Product catalog UI · sw.js Service worker
Components 18
Storefront pages
- Home
index.html - Products page
products.html - Wishlist page
wishlist.html - Cart page
cart.html - Checkout page
checkout.html - Feedback page
feedback.html
Shopping features
- Product catalog UI
script.js - Cart operations
script.js - Cart totals
script.js - Checkout flow
script.js - Wishlist operations
script.js - Browser storage
Engagement features
- Promotional features
script.js - Feedback form
script.js - FAQ accordion
script.js
Offline support
- Service worker
sw.js - Cache storage
Other components
- Shopper
Connections 8
- Product catalog UI → Cart operations: adds items
script.js - Product catalog UI → Wishlist operations: toggles items
script.js - Cart operations → Browser storage: saves cart
script.js - Wishlist operations → Browser storage: saves list
script.js - Checkout flow → Cart totals: gets totals
script.js - Feedback form → Browser storage: saves feedback
script.js - Service worker → Cache storage: caches files
sw.js - Service worker → Cache storage: checks cached files
sw.js