Proje: Okul B2B App · Hub: Okul B2B App — Conventions
Development Araçları ve Debug Yardımcıları
DevInfoBanner
components/DevInfoBanner.tsx — Sadece Expo Go’da görünür (isExpoGo === true).
Gösterilen bilgiler:
- Aktif API URL (
api.okul.workveyaapi.okul.com.tr) x-consumer-keydeğeri- Environment (
development,staging,production)
Üç mod:
collapsed— Kompakt badgeexpanded— Tam detayhidden— Küçük “D” noktası
Bu bileşen RootLayout’ta tüm ekranların üstünde gösterilir. Production build’larda tamamen gizlenir.
test-api-errors.tsx
app/test-api-errors.tsx — Development-only test ekranı. Farklı API hata senaryolarını test etmek için.
console.log Temizleme
scripts/replace-console-logs.js — Tüm console.log’ları logger.log’a çeviren script.
Geliştirme Komutları
npm start # Expo dev server (EXPO_NO_WATCHMAN=1)
npm run start:dev-client # Dev client ile başlat
npm run android / ios # Cihazda çalıştır
# Build info
npm run build-info # Build bilgisi göster
# Versiyon
npm run version:patch # Patch version artır
npm run version:minor # Minor version artır
# OTA (İzin al önce!)
npm run test:onesignal # OneSignal test notification
# Lint
npm run lint # ESLint çalıştırLogger Debug Modu
EXPO_PUBLIC_DEBUG_MODE=true
EXPO_PUBLIC_LOG_LEVEL=debug
Development build’da tüm logger.info/warn/debug console’a yazılır.
Related
- firebase-native-module-kurali — Expo Go tespiti
- environment-ve-env-degiskenleri — debug değişkenleri