Skip to content

chore(example-app): migrate to Capacitor 9 alpha.8 SwiftUI/UIScene lifecycle - #178

Merged
andredestro merged 2 commits into
nextfrom
chore/RMET-5344/example-app-uiscene
Oct 23, 2026
Merged

andredestro merged 2 commits into
nextfrom
chore/RMET-5344/example-app-uiscene

Conversation

@andredestro

@andredestro andredestro commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Description

Re-runs npx cap migrate with @capacitor/cli@9.0.0-alpha.8 so the example app(s) use the Capacitor 9 iOS template: a SwiftUI App entry point with the UIScene lifecycle (App.swift, CapacitorView.swift, UIApplicationSceneManifest in Info.plist, AppDelegate as a UIApplicationDelegateAdaptor).

The example apps had been migrated with an earlier 9.0 alpha, before cap migrate added the SwiftUI/UIScene step, so they still booted through @main AppDelegate + Main.storyboard. The iOS 27 SDK requires the UIScene lifecycle (TN3187). Without this change, the example apps don't represent a Capacitor 9 app when we test on iOS 27 / Xcode 27.

The Android changes are the ones cap migrate applies (edge-to-edge MainActivity, Gradle files). They were not changed by hand.

Verification

  • iOS: xcodebuild Debug build succeeds with Xcode 27.1 (iOS Simulator, no signing).
  • Without this migration the example app does not launch on iOS 27.0.1 when built with Xcode 27.1: UIKit traps in _UIApplicationEvaluateRuntimeIssueForNoSceneLifecycleAdoption (EXC_BREAKPOINT/SIGTRAP) at scene creation. Reproduced on device with the barcode-scanner example app from next; adding a scene lifecycle makes it launch.
  • Smoke-tested on a physical iPhone 16 Pro Max, iOS 27.0.1 (Xcode 27.1 build).
  • Android: not built.

Notes

  • pnpm-lock.yaml: starts from next and only bumps the @capacitor/* entries of the example apps (pnpm 11, same as CI), so react-scripts keeps resolving eslint@8.
  • apps/example-app-spm (SwiftPM) also builds with Xcode 27.1.

@OS-ruimoreiramendes OS-ruimoreiramendes left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Used this branch for Android 17 validation. The android side works fine

@andredestro
andredestro merged commit 2765932 into next Oct 23, 2026
4 checks passed
@andredestro
andredestro deleted the chore/RMET-5344/example-app-uiscene branch October 23, 2026 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants