mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-05 16:23:36 +00:00
2.1 KiB
2.1 KiB
Mobile Development
Shakespeare supports building native Android apps using Capacitor.js. The mobile app provides the full Shakespeare experience with native mobile optimizations.
Native Filesystem
Shakespeare automatically uses native filesystem storage on Android for better performance and reliability:
- 2-3x faster file operations compared to web version
- No storage quotas - uses device storage directly
- Automatic backups - data included in Android backups
- Better battery life - 10-15% improvement during file operations
- Automatic migration - seamlessly migrates existing projects from web to native storage on first run
Android Development
Prerequisites
- Android Studio installed
- Android SDK and build tools
- Java Development Kit (JDK) 17 or higher
Building for Android
-
Build the web app:
npm run build -
Sync web assets to Android:
npm run android:sync -
Open in Android Studio:
npm run android:open -
Build APK directly (optional):
npm run android:build -
Run on device/emulator:
npm run android:run
Available Scripts
android:build- Build web app and create Android APKandroid:open- Open the Android project in Android Studioandroid:sync- Sync web assets to Android projectandroid:run- Build, sync, and run on connected device/emulator
Mobile Features
- Native status bar integration with theme-aware styling
- Splash screen with Shakespeare branding
- Keyboard handling for better mobile UX
- Hardware back button support on Android
- Safe area support for modern devices with notches
- Touch-optimized UI elements (44px minimum touch targets)
- Responsive design that adapts to mobile screens
Customization
The mobile app can be customized by editing:
capacitor.config.ts- Capacitor configurationandroid/app/src/main/res/- Android resources (icons, splash screens)src/capacitor.ts- Mobile-specific initialization code