Ecom
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Viewing readonly version of main branch: v8View latest version
A modern e-commerce website for shoes built with React, Hono, and SQLite.
- Product catalog with filtering and search
- Shopping cart functionality
- Product details with image gallery
- Responsive design with TailwindCSS
- Admin panel for product management
- SQLite database for data persistence
├── backend/
│ ├── database/
│ │ ├── migrations.ts # Database schema
│ │ └── queries.ts # Database operations
│ ├── routes/
│ │ ├── products.ts # Product API routes
│ │ └── cart.ts # Cart API routes
│ └── index.ts # Main Hono server
├── frontend/
│ ├── components/
│ │ ├── App.tsx # Main app component
│ │ ├── ProductCard.tsx # Product display component
│ │ ├── Cart.tsx # Shopping cart component
│ │ └── ProductDetail.tsx # Product detail view
│ ├── index.html # Main HTML template
│ └── index.tsx # Frontend entry point
└── shared/
└── types.ts # Shared TypeScript types
## Getting Started
1. The backend runs on Hono with SQLite for data storage
2. The frontend is a React SPA with TailwindCSS for styling
3. Products are pre-seeded with sample shoe data
4. Cart functionality works with local storage and API persistence
## API Endpoints
- `GET /api/products` - Get all products
- `GET /api/products/:id` - Get product by ID
- `POST /api/cart` - Add item to cart
- `GET /api/cart` - Get cart items
- `DELETE /api/cart/:id` - Remove item from cart