Verify platform-specific code works correctly on both iOS and Android
Scans the codebase for platform-specific code patterns and verifies that both iOS and Android are properly handled. Identifies missing platform checks, inconsistent behaviour, and platform-specific bugs.
/platform-check # Check all source files
/platform-check app/ # Check only screen files
/platform-check components/ # Check only components
Search the codebase for platform-specific patterns:
# Find Platform.OS usage
grep -rn "Platform\.OS" app/ components/ hooks/ --include="*.tsx" --include="*.ts"
# Find Platform.select usage
grep -rn "Platform\.select" app/ components/ hooks/ --include="*.tsx" --include="*.ts"
# Find platform-specific file extensions
find . -name "*.ios.tsx" -o -name "*.android.tsx" | head -50
# Find SafeAreaView usage
grep -rn "SafeAreaView\|useSafeAreaInsets" app/ components/ --include="*.tsx"
# Find KeyboardAvoidingView without platform check
grep -rn "KeyboardAvoidingView" app/ components/ --include="*.tsx"
# Find shadow styles (different on iOS vs Android)
grep -rn "shadowColor\|shadowOffset\|elevation" app/ components/ constants/ --include="*.tsx" --include="*.ts"
For each platform-specific pattern found, verify:
behavior prop is platform-specific ('padding' on iOS, 'height' on Android)keyboardVerticalOffset accounts for navigation header on iOSkeyboardShouldPersistTaps="handled" on ScrollViews inside formsshadowColor/shadowOffset without platform checkconstants/shadows.ts are usedelevation propertyshadowColor, shadowOffset, shadowOpacity, shadowRadiusPressable preferred over TouchableOpacityandroid_ripple set on Pressable components## Platform Check Report
### Summary
- **Files scanned:** N
- **Platform-specific patterns found:** N
- **Issues found:** N (X critical, Y warning)
### Critical Issues (Must Fix)
1. `app/(tabs)/items.tsx:45` - KeyboardAvoidingView missing platform-specific
behavior prop. Currently hardcoded to 'padding' which breaks on Android.
2. `components/ui/Card.tsx:22` - Shadow styles use iOS-only properties without
Android elevation fallback.
### Warnings
1. `app/(tabs)/dashboard.tsx` - No FAB on Android for the "add" action.
iOS has a header button but Android has no equivalent.
2. `components/forms/SearchBar.tsx` - No android_ripple on Pressable.
### Platform Coverage Matrix
| Screen/Component | iOS Header Btn | Android FAB | SafeArea | Keyboard | Shadows |
|-----------------|----------------|-------------|----------|----------|---------|
| ItemsScreen | Yes | Yes | Yes | N/A | N/A |
| ItemFormScreen | Yes (Save) | Yes (Save) | Yes | Yes | N/A |
| Card | N/A | N/A | N/A | N/A | Yes |
| SearchBar | N/A | N/A | N/A | Yes | N/A |
### Recommendations
- <actionable suggestions for improving cross-platform consistency>
Write results to .agent-pipeline/platform-check.md if running as part of the
pipeline.
behavior="padding" without platform checkelevation without iOS shadow propertiesSearch for places (restaurants, cafes, etc.) via Google Places API proxy on localhost.
Interact with GitHub using the `gh` CLI. Use `gh issue`, `gh pr`, `gh run`, and `gh api` for issues, PRs, CI runs, and advanced queries.
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.
Start voice calls via the OpenClaw voice-call plugin.
Notion API for creating and managing pages, databases, and blocks.
Gemini CLI for one-shot Q&A, summaries, and generation.
Category:developer