Skillshub ios-app-lifecycle
Standards for AppDelegate, SceneDelegate, Deep Linking, and Background Tasks. Use when managing iOS app lifecycle, deep linking, or background task scheduling. (triggers: AppDelegate.swift, SceneDelegate.swift, didFinishLaunchingWithOptions, willConnectTo, backgroundTask, Shortcut, UserActivity)
install
source · Clone the upstream repo
git clone https://github.com/ComeOnOliver/skillshub
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/ComeOnOliver/skillshub "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/HoangNguyen0403/agent-skills-standard/ios-app-lifecycle" ~/.claude/skills/comeonoliver-skillshub-ios-app-lifecycle && rm -rf "$T"
manifest:
skills/HoangNguyen0403/agent-skills-standard/ios-app-lifecycle/SKILL.mdsource content
iOS App Lifecycle Standards
Priority: P0
Implementation Guidelines
App & Scene Delegate
- SceneDelegate: Use for UI windows and scene-specific state in iOS 13+.
- AppDelegate: Focus on app-wide setup (DI, Analytics, Push notification registration).
- Slim Delegates: Move initialization logic to dedicated
orBootstrapper
.AppCoordinator
Deep Linking
- Universal Links: Prefer over custom URL schemes. Handle via
.scene(_:continue:userActivity:) - Handling logic: Routing should be handled by the Root Coordinator to navigate to specific screens.
Background Tasks
- Background Fetch: Use
for periodically refreshing data.BGTaskScheduler - Expiration: Handle
to avoid app kill by the system.expirationHandler
Anti-Patterns
- No complex logic in didFinishLaunching: Use a Bootstrapper service.
- No UIWindow setup in AppDelegate: Use SceneDelegate for iOS 13+.
- No synchronous network calls in launch: Move to background thread.