Files
actual/packages/mobile/capacitor.config.ts
Claude 22a5bff977 [AI] Add Capacitor iOS app wrapper for App Store publishing
Wraps the existing PWA mobile web app in a Capacitor iOS shell for
publishing to the iOS App Store. Uses the existing 54+ mobile-optimized
React components and local-first SQLite storage (via absurd-sql/IndexedDB).

Key additions:
- packages/mobile/ - New Capacitor workspace with iOS platform
- Custom ActualBridgeViewController for WKWebView configuration
- CrossOriginIsolationPlugin for SharedArrayBuffer support
- Build scripts: yarn build:mobile, yarn mobile:open, yarn mobile:run:ios
- iOS deployment target set to 16.0 (required for SAB in WKWebView)
- App Transport Security configured for local networking

https://claude.ai/code/session_01GAVpnQ21dPw6KJVf5c4f5D
2026-03-21 10:59:02 +00:00

47 lines
1.3 KiB
TypeScript

import type { CapacitorConfig } from '@capacitor/cli';
const config: CapacitorConfig = {
appId: 'org.actualbudget.mobile',
appName: 'Actual Budget',
// Point to the desktop-client build output
webDir: '../desktop-client/build',
server: {
// Serve from localhost to enable COOP/COEP headers,
// which are required for SharedArrayBuffer (used by absurd-sql).
// On iOS, this uses WKURLSchemeHandler with the http scheme,
// allowing cross-origin isolation to work in WKWebView.
iosScheme: 'http',
androidScheme: 'http',
},
ios: {
// Minimum iOS version that supports SharedArrayBuffer in WKWebView
// with cross-origin isolation headers (iOS 15.2+)
minVersion: '16.0',
// Allow inline media playback (needed for some UI interactions)
allowsLinkPreview: false,
contentInset: 'always',
preferredContentMode: 'mobile',
},
plugins: {
SplashScreen: {
launchAutoHide: true,
launchShowDuration: 2000,
backgroundColor: '#5c3dbb',
showSpinner: false,
iosSpinnerStyle: 'small',
splashFullScreen: true,
splashImmersive: true,
},
Keyboard: {
resize: 'body',
resizeOnFullScreen: true,
},
StatusBar: {
style: 'LIGHT',
backgroundColor: '#5c3dbb',
},
},
};
export default config;