๐งช Local Development โ
Before building for the app stores, test the app on your own phone or simulator to make sure everything works.
1๏ธโฃ Step 1: Install Expo CLI โ
npm install -g expo-cli eas-cli2๏ธโฃ Step 2: Start the Development Server โ
cd packages/mobile
npx expo startThis starts the Expo development server and shows a QR code in your terminal.
3๏ธโฃ Step 3: Run on Your Phone โ
๐ฑ Using Expo Go (Quickest) โ
Install the Expo Go app on your phone:
- ๐ iOS App Store
- ๐ค Google Play Store
๐ธ Scan the QR code:
- iPhone: Open the Camera app and point it at the QR code
- Android: Open Expo Go and tap "Scan QR code"
โ The app will load on your phone.
โ ๏ธ Expo Go Limitations
Expo Go is great for quick testing, but some features (push notifications, Stripe payments) won't work in Expo Go because they require native modules. For full testing, use a development build.
๐ฅ๏ธ Using a Simulator/Emulator โ
๐ iOS Simulator (Mac only) โ
- Install Xcode from the Mac App Store
- Open Xcode โ Settings โ Platforms โ Install iOS Simulator
- Run:
npx expo start --ios
๐ค Android Emulator โ
- Install Android Studio
- Open Android Studio โ More Actions โ Virtual Device Manager โ Create Device
- Choose a device (e.g., Pixel 7) and download a system image
- Run:
npx expo start --android
4๏ธโฃ Step 4: Connect to Your API Server โ
The app needs to reach your KitchenAsty API server. During development, you have several options:
๐ Option A: Local Server on Same Machine โ
If the API server is running on the same computer (e.g., via docker compose up):
Edit packages/mobile/app.json and set apiBaseUrl to your computer's local IP:
{
"expo": {
"extra": {
"apiBaseUrl": "http://192.168.1.100:3000"
}
}
}Find your local IP with:
- ๐ Mac:
ipconfig getifaddr en0 - ๐ง Linux:
hostname -I | awk '{print $1}' - ๐ช Windows:
ipconfig(look for IPv4 Address)
โ ๏ธ
Don't use localhost or 127.0.0.1 โ that refers to the phone itself, not your computer. Use your computer's actual IP address on the local network.
๐ Option B: Production Server โ
Point the app directly at your production server:
{
"expo": {
"extra": {
"apiBaseUrl": "https://api.yourdomain.com"
}
}
}This is the simplest option and tests the real connection.
5๏ธโฃ Step 5: Test Core Flows โ
Walk through these flows to verify everything works:
โ Basic Testing Checklist โ
Here's what each screen should look like when working correctly:
| Home Screen | Menu Screen | Item Detail |
|---|---|---|
![]() | ![]() | ![]() |
- [ ] ๐ App loads and shows the home screen
- [ ] ๐ Menu screen displays categories and items
- [ ] ๐ Tapping a menu item opens the detail modal
- [ ] ๐ Adding an item to the cart works
- [ ] ๐ฐ Cart shows correct items and subtotal
- [ ] ๐ Register a new account
- [ ] ๐ Log in with the account
- [ ] ๐ฆ Place a test order (cash payment)
- [ ] โ Order confirmation screen shows
- [ ] ๐ Order history displays the order
- [ ] ๐ Locations page shows your restaurant(s)
- [ ] ๐ Language switcher changes the UI language
๐ณ Testing Stripe Payments โ
Stripe payments require a development build (not Expo Go). Use Stripe's test card numbers:
| Card Number | Result |
|---|---|
โ
4242 4242 4242 4242 | Successful payment |
โ 4000 0000 0000 9995 | Declined payment |
Use any future expiry date and any 3-digit CVC.
๐จ Development Build โ
For testing features that don't work in Expo Go (push notifications, Stripe), create a development build:
# Install the dev client
npx expo install expo-dev-client
# Build for your device
eas build --profile development --platform android
# or for iOS:
eas build --profile development --platform iosThis creates a custom version of the app with all native modules included. Install it on your device and connect it to the Expo development server.
๐ง Common Issues โ
โ "Network request failed" โ
The app can't reach the API server. Check:
- โ
The
apiBaseUrlinapp.jsonis correct - ๐ถ Your phone and computer are on the same WiFi network (for local servers)
- ๐ฅ๏ธ The API server is running (
curl http://your-ip:3000/api/health)
๐ด Metro bundler errors โ
# Clear the cache and restart
npx expo start --clear๐ฆ "Unable to resolve module" โ
# Reinstall dependencies
rm -rf node_modules
npm installโก๏ธ Next Step โ
Once you've verified the app works, continue to EAS Build Setup to configure cloud builds.


