iOS product analytics installation
PostHog is available through CocoaPods or you can add it as a Swift Package Manager based dependency.
CocoaPods
Podfile
Swift Package Manager
Add PostHog as a dependency in your Xcode project "Package Dependencies" and select the project target for your app, as appropriate.
For a Swift Package Manager based project, add PostHog as a dependency in your Package.swift file's Package dependencies section:
Package.swift
and then as a dependency for the Package target utilizing PostHog:
Package.swift
Configuration
Configuration is done through the PostHogConfig object. Here's a basic configuration example to get you started.
You can find more advanced configuration options in the configuration page.
Swift