Skip to main content

Prerequisites

Before you begin, ensure you have the following installed:

Node.js

Version 18.x or higher

pnpm

Preferred package manager

Supabase CLI

For local database

Xcode

For iOS development (Mac only)
  • Xcode 15+
  • iOS Simulator

1. Clone the Repositories

2. Setup Supabase Backend

1

Start Supabase locally

This will output your local Supabase credentials. Save these!
2

Note the credentials

3

Run migrations

3. Setup Web Store

1

Install dependencies

2

Create .env.local

.env.local
3

Update hosts file

Add test subdomains to /etc/hosts:
Add these lines:
4

Run dev server

4. Setup iOS App (Mac only)

1

Install dependencies

2

Configure Supabase

Update Configuration/Development.xcconfig:
3

Open in Xcode

4

Run on simulator

  1. Select a simulator (iPhone 15 Pro)
  2. Press Cmd + R to build and run

Test Data

The local Supabase instance comes with seed data:
  • 5 sample products with images
  • 2 categories (Electronics, Clothing)
  • Various price points
  • 3 pending orders
  • 2 completed orders
  • Mix of UPI and Razorpay payments

Verify Setup

Visit http://teststore.localhost:3000You should see:
  • ✅ Store homepage with products
  • ✅ Working cart functionality
  • ✅ Checkout flow

Troubleshooting

Make sure you:
  1. Updated /etc/hosts with test domains
  2. Using .localhost:3000 (not localhost:3000)
  3. Middleware is detecting subdomains correctly
Check middleware logs:
Verify Supabase is running:
Check .env.local has correct credentials:
Common fixes:
  1. Clean build folder: Cmd + Shift + K
  2. Delete derived data
  3. Update Swift package dependencies
  4. Restart Xcode
Stuck? Join our Discord or create an issue on GitHub