Libraries I consider for a new iOS project

#ios#libraries#cocoapods

I do not add the same dependencies to every iOS project. Each dependency adds maintenance work, so it should solve a clear problem.

Still, a short list helps when I start a project. These are the libraries and tools that I consider first.

User interface#

I prefer SwiftUI for new interfaces, so this section does not include UIKit-specific libraries.

Kingfisher#

Kingfisher handles common image downloading, caching, and display tasks:

I consider Kingfisher when an app loads many remote images or needs more control than a small custom loader provides.

Networking#

Alamofire#

Alamofire is a Swift Hypertext Transfer Protocol (HTTP) networking library. Its interface builds on Apple’s Foundation networking stack.

Alamofire can:

Foundation can handle many networking needs without another dependency. I consider Alamofire when its request adapters, retries, or response handling remove meaningful project code.

Security#

KeychainAccess#

iOS apps must protect passwords, authentication tokens, and other credentials. KeychainAccess wraps Keychain with a smaller Swift interface.

KeychainAccess provides these features:

Tools#

Firebase/Crashlytics#

Firebase Crashlytics is a crash-reporting tool from Google’s Firebase platform. It helps teams investigate crashes that affect users.

Firebase Crashlytics provides these capabilities:

SwiftLint#

SwiftLint enforces Swift style and conventions in your codebase. Its configurable rules can match your team’s coding standards and preferences.

SwiftLint provides:

Integrate the dependencies with CocoaPods#

This example uses CocoaPods as the dependency manager. Add the dependencies that your project needs to its Podfile:

Podfile
# User Interface
pod 'Kingfisher'
# Networking
pod 'Alamofire'
# Security
pod 'KeychainAccess'
# Tools
pod 'Firebase/Crashlytics'
pod 'SwiftLint'

Treat this list as a starting point, not a project template. Before you add a dependency, check its maintenance status and confirm that the project needs it.