examples/storefront Public
storefront knowledge base
How the storefront works and why it is built this way. Start with the concept notes, then read the decisions for the reasoning behind them. The architecture tab has the map of Workers and storage these notes refer to.
Concepts
- [[catalog]]: products, prices and stock, and how the merchant edits them.
- [[carts]]: what a cart holds and the limits it enforces.
- [[product-images]]: how images get into R2 and back out.
Decisions
- [[0001-d1-for-shop-data]]: one D1 database for everything the shop sells.
- [[0002-serve-images-through-the-api]]: images are served by storefront-api.
- [[0003-money-in-whole-cents]]: prices and totals are integers.
Guides
- [[testing]]: how the tests run the real SQL without workerd.