# iOS App Lifecycle, Xcode Projects & Capabilities

> Scenes and app lifecycle, Info.plist, targets and schemes, capabilities and entitlements, and debugging in Xcode. Free notes, key concepts, resources and a...

Canonical: https://www.internhack.in/roadmaps/tracks/mobile/ios-fundamentals
Last updated: 2026-11-28

Scenes and app lifecycle, Info.plist, targets and schemes, capabilities and entitlements, and debugging in Xcode.

Intermediate · about 7 hours · difficulty 3/5

Learn first: [Native iOS (Swift + SwiftUI)](https://www.internhack.in/roadmaps/tracks/mobile/native-ios), [Swift Essentials](https://www.internhack.in/roadmaps/tracks/mobile/swift)

Before going deep on SwiftUI, get comfortable with how an iOS app is packaged and launched.

### Lifecycle

In SwiftUI apps, the `App` struct declares `WindowGroup` scenes. Observe `@Environment(\.scenePhase)` to react when the app becomes `active`, `inactive` or `background`. iOS suspends backgrounded apps quickly and may terminate them without notice, so persist state early.

### Project structure

- **Targets**: the app, extensions (widgets, notification service), and test targets.
- **Schemes and build configurations**: Debug vs Release, plus custom ones for staging.
- **Info.plist**: bundle metadata and **usage description strings** (for example `NSCameraUsageDescription`) required before asking for permissions. Missing strings crash the app.
- **Capabilities and entitlements**: push notifications, iCloud, Sign in with Apple, App Groups.
- **Asset catalogs** for app icons, colours and images.

### Debugging

Breakpoints, the LLDB console (`po variable`), the view hierarchy debugger, and Instruments for performance.

### UIKit awareness

Many SDKs and older apps still use UIKit. `UIViewRepresentable` and `UIViewControllerRepresentable` wrap UIKit components for SwiftUI.

**Good enough to move on:** you can add a capability, add a permission usage string, create a staging configuration, and debug with breakpoints.

## Key concepts

- **App, Scene and scenePhase**
- **Targets, schemes and configurations**
- **Info.plist and usage descriptions**
- **Capabilities and entitlements**
- **Asset catalogs**
- **Debugging with breakpoints and LLDB**
- **Wrapping UIKit in SwiftUI**

## Mini project

Build a journaling app that saves the current draft whenever the app goes to the background, with separate Debug and Staging configurations.

## Check yourself

What happens if your app requests camera access without an NSCameraUsageDescription entry?

## Free resources

- [Xcode documentation](https://developer.apple.com/documentation/xcode) (Apple)
- [App and environment (SwiftUI)](https://developer.apple.com/documentation/swiftui/app-structure-and-behavior) (Apple)
- [SwiftUI tutorials](https://developer.apple.com/tutorials/swiftui) (Apple)

Previous: [Modern Android Architecture: ViewModel, Flow, Hilt & Room](https://www.internhack.in/roadmaps/tracks/mobile/android-architecture) · Next: [SwiftUI Data Flow & Composition](https://www.internhack.in/roadmaps/tracks/mobile/swiftui-in-depth)

## More in iOS with Swift in Depth

- [iOS App Lifecycle, Xcode Projects & Capabilities](https://www.internhack.in/roadmaps/tracks/mobile/ios-fundamentals)
- [SwiftUI Data Flow & Composition](https://www.internhack.in/roadmaps/tracks/mobile/swiftui-in-depth)
- [Swift Concurrency & Persistence (SwiftData, Core Data)](https://www.internhack.in/roadmaps/tracks/mobile/ios-concurrency-data)

## Related

- [Roadmaps](https://www.internhack.in/roadmaps)
- [Mobile App Developer Roadmap](https://www.internhack.in/roadmaps/tracks/mobile)
