Skip to content

feat: Capacitor iOS integration prep#88

Merged
AdamJ merged 3 commits intomainfrom
claude/capacitor-ios-planning-18tPM
Apr 25, 2026
Merged

feat: Capacitor iOS integration prep#88
AdamJ merged 3 commits intomainfrom
claude/capacitor-ios-planning-18tPM

Conversation

@AdamJ
Copy link
Copy Markdown
Owner

@AdamJ AdamJ commented Apr 24, 2026

  • Switch BrowserRouter → HashRouter (Capacitor loads from filesystem,
    history-API paths 404 without a server)
  • Add VITE_IOS_BUILD flag (set via npm run build:ios / --mode ios)
    that disables VitePWA SW registration for native builds
  • Gate InstallPrompt and UpdateNotification behind !isIosBuild in App.tsx;
    tree-shaking confirms auth components absent from iOS bundle
  • Hide UserMenu, AuthDialog, SyncStatus in Navigation.tsx for iOS —
    local-only storage means no sign-in or sync UI is needed
  • Replace window.location.reload() in Settings with window.location.replace()
    to avoid interrupting the Capacitor JS bridge on data clear
  • Add capacitor://localhost to CSP directives so WKWebView can load assets
  • Add .env.ios with VITE_IOS_BUILD=true (no Supabase keys → localStorage mode)
  • Add build:ios npm script (vite build --mode ios)

- Switch BrowserRouter → HashRouter (Capacitor loads from filesystem,
  history-API paths 404 without a server)
- Add VITE_IOS_BUILD flag (set via npm run build:ios / --mode ios)
  that disables VitePWA SW registration for native builds
- Gate InstallPrompt and UpdateNotification behind !isIosBuild in App.tsx;
  tree-shaking confirms auth components absent from iOS bundle
- Hide UserMenu, AuthDialog, SyncStatus in Navigation.tsx for iOS —
  local-only storage means no sign-in or sync UI is needed
- Replace window.location.reload() in Settings with window.location.replace()
  to avoid interrupting the Capacitor JS bridge on data clear
- Add capacitor://localhost to CSP directives so WKWebView can load assets
- Add .env.ios with VITE_IOS_BUILD=true (no Supabase keys → localStorage mode)
- Add build:ios npm script (vite build --mode ios)

https://claude.ai/code/session_01P4dgLTrB7NAGpr1qBiG3jz
@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Apr 24, 2026

Deploying timetrackerpro with  Cloudflare Pages  Cloudflare Pages

Latest commit: 788c8d4
Status: ✅  Deploy successful!
Preview URL: https://5c018cd5.timetrackerpro.pages.dev
Branch Preview URL: https://claude-capacitor-ios-plannin.timetrackerpro.pages.dev

View logs

@AdamJ AdamJ self-assigned this Apr 24, 2026
@AdamJ AdamJ added the enhancement New feature or request label Apr 24, 2026
@AdamJ AdamJ changed the title feat: Phase 1 Capacitor iOS integration prep feat: Capacitor iOS integration prep Apr 25, 2026
@AdamJ AdamJ linked an issue Apr 25, 2026 that may be closed by this pull request
claude and others added 2 commits April 25, 2026 09:56
- Install @capacitor/core, @capacitor/ios (deps) and @capacitor/cli (devDep)
- Write capacitor.config.ts: appId com.adamjolicoeur.timetrackerpro,
  webDir dist, contentInset always, scrollEnabled false,
  limitsNavigationsToAppBoundDomains true
- npx cap add ios → generates ios/ Xcode project (Capacitor 8.3.1,
  iOS 15+ minimum via Package.swift SPM)
- npx cap sync ios → web assets and config confirmed copied cleanly
- Bundle ID com.adamjolicoeur.timetrackerpro wired into project.pbxproj
- Add sync:ios script (build:ios + cap sync ios in one command)
- ios/App/App/public gitignored (regenerated on every sync)

https://claude.ai/code/session_01P4dgLTrB7NAGpr1qBiG3jz
@AdamJ AdamJ force-pushed the claude/capacitor-ios-planning-18tPM branch from c042820 to 788c8d4 Compare April 25, 2026 13:56
@AdamJ AdamJ merged commit 9e57f31 into main Apr 25, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Major: Convert to iOS App

2 participants