2.8 KiB
2.8 KiB
Local Testing - Bagsy on iPhone 16
Quick guide to test Bagsy locally on your Mac and iPhone 16.
Setup (One-time)
Prerequisites
- Mac with Xcode (or
xcode-select --install) - iPhone 16 (or iOS Simulator)
bunpackage managereas-cli:npm install -g eas-cli- Expo account (free, sign up at expo.dev)
Testing Workflow
Step 1: Start Backend (Terminal 1)
cd apps/api
bun run dev
Server runs on http://localhost:3001
Step 2: Build for Device (Terminal 2)
Option A: Cloud Build (RECOMMENDED - Fastest)
cd apps/mobile
bun run build:dev:ios
- Builds in the cloud (no local setup needed)
- Download
.ipafrom https://expo.dev/builds - Sideload with Transporter or Apple Configurator 2
- See
docs/iOS_SIDELOADING_GUIDE.mdfor detailed instructions
Option B: Local Prebuild (Xcode)
cd apps/mobile
bun run prebuild
pod install --repo-update # If needed
open ios/Bagsy.xcworkspace
Then in Xcode:
- Select Bagsy target → Signing & Capabilities
- Set Team to your Apple ID
- Connect iPhone, select in scheme
- Click Play (Cmd+R)
See apps/mobile/PREBUILD_STATUS.md for current build status.
Step 3: Install on iPhone
Cloud Build (.ipa file):
- Use Transporter or Apple Configurator 2
- See
docs/iOS_SIDELOADING_GUIDE.mdfor detailed instructions
Local Prebuild (via Xcode):
- Xcode handles installation automatically
Step 4: Trust App (if prompted)
On iPhone:
- Settings → General → VPN & Device Management
- Tap your Apple ID
- Trust the app
What You Can Test
✅ Icon (Bagsy with shopping bag)
✅ Auth (sign-up, sign-in, passkey)
✅ Lists (create, edit, delete)
✅ Items (add, check off, remove)
✅ Real-time sync
✅ Camera/barcode scanning
✅ Device performance
Troubleshooting
| Issue | Fix |
|---|---|
| Backend won't start | Check port 3001: lsof -i :3001 |
| Can't connect to backend | Verify WiFi, check EXPO_PUBLIC_API_URL in .env |
| Prebuild fails | Use cloud build (bun run build:dev:ios) |
| App won't install | Make sure you trust it in iPhone Settings |
| Blank screen | Check Xcode console for errors |
Key Files
- Backend:
apps/api/ - Mobile:
apps/mobile/ - Backend env:
apps/api/.env.local - Mobile env:
apps/mobile/.env - Sideloading guide:
docs/iOS_SIDELOADING_GUIDE.md - EAS config:
eas.json
Next Steps
- Test locally to verify everything works
- When ready: Deploy to App Store via
bun run build:ios - For beta testing: Use TestFlight (see
docs/iOS_SIDELOADING_GUIDE.md)