How bruno-sf-dev/sneaker-store works
SNKRS is a Next.js sneaker storefront. Shoppers browse a filterable, sortable, paginated catalog or search by URL query, open sneaker detail pages, and add products to a cart. The graph keeps listing, search, detail, and cart as distinct product stages, with API services and URL-driven catalog state as internal layers. Edges are limited to relationships visible in excerpts or the SOURCE INDEX; several unsampled UI and API internals are therefore shown without speculative connections.
Main entry points: (home)/page.tsx Catalog page · home-product-list/index.tsx Product listing · search/page.tsx Search page · search-product-list/index.tsx Search results
Components 21
Catalog browsing
- Catalog page
src/app/(store)/(home)/page.tsx - Product listing
src/app/(store)/(home)/components/home-product-list/index.tsx - Filter controls
src/app/(store)/(home)/components/home-sidebar-filter - Sort controls
src/app/(store)/(home)/components/home-sort-by/index.tsx - Pagination
src/app/(store)/(home)/components/home-pagination/index.tsx - Grid layout state
src/contexts/home-layout-context.tsx
Search and product detail
- Search form
src/components/app-header/header-search-form/index..tsx - Search page
src/app/(store)/search/page.tsx - Search results
src/app/(store)/search/components/search-product-list/index.tsx - Product page
src/app/(store)/product/[slug]/page.tsx - Product details
src/app/(store)/product/[slug]/components/product-view/index.tsx - Add to cart
src/app/(store)/product/[slug]/components/product-info-to-buy/index.tsx
Shared storefront UI
- Product card
src/components/product-card/index.tsx - Loading skeleton
src/components/skeletons/skeleton.tsx
Data and state
- Cart state
src/contexts/cart-context.tsx - API client
src/api/api.ts - Catalog service
src/api/services/get-all-sneakers.ts - Search service
src/api/services/get-search-sneakers.ts - Sneaker service
src/api/services/get-sneaker.ts - Sneaker model
src/api/data/types/sneakers.ts
Other components
- Shopper
Connections 26
- Shopper → Catalog page: browses
- Shopper → Search form: searches
- Shopper → Product page: opens product
- Catalog page → Product listing: renders
src/app/(store)/(home)/page.tsx - Catalog page → Filter controls: renders
src/app/(store)/(home)/page.tsx - Catalog page → Sort controls: renders
src/app/(store)/(home)/page.tsx - Catalog page → Grid layout state: provides state
src/app/(store)/(home)/page.tsx - Product listing → Catalog service: fetches catalog
src/app/(store)/(home)/components/home-product-list/index.tsx - Product listing → Product card: renders items
src/app/(store)/(home)/components/home-product-list/index.tsx - Product listing → Pagination: renders
src/app/(store)/(home)/components/home-product-list/index.tsx - Catalog page → Loading skeleton: shows loading
src/app/(store)/(home)/page.tsx - Search form → Search page: submits query
- Search page → Search results: renders
src/app/(store)/search/page.tsx - Search page → Loading skeleton: shows loading
src/app/(store)/search/page.tsx - Search results → Search service: fetches matches
src/app/(store)/search/components/search-product-list/index.tsx - Search results → Product card: renders items
src/app/(store)/search/components/search-product-list/index.tsx - Product page → Product details: renders
src/app/(store)/product/[slug]/page.tsx - Product details → Sneaker service: fetches sneaker
src/app/(store)/product/[slug]/components/product-view/index.tsx - Product details → Add to cart: renders purchase
src/app/(store)/product/[slug]/components/product-view/index.tsx - Product page → Loading skeleton: shows loading
src/app/(store)/product/[slug]/page.tsx - Add to cart → Cart state: adds item
- Catalog service → API client: requests data
src/api/services/get-all-sneakers.ts - Search service → API client: requests data
src/api/services/get-search-sneakers.ts - Catalog service → Sneaker model: returns sneakers
src/api/services/get-all-sneakers.ts - Search service → Sneaker model: returns sneakers
src/api/services/get-search-sneakers.ts - Product card → Sneaker model: displays sneaker
src/components/product-card/index.tsx