This is an example of how to use the PostHog iOS SDK with SPM.
- Install Xcode if you haven't already:
Follow steps from the Xcode docs.
- Click on the project in the Project Navigator.
- Select the project in the Project and Targets list.
- Select the General tab.
- Scroll down to the Frameworks and Libraries section.
- Click the + button.
- Click Add Other...
- Click Add Package Dependency
- Enter the URL of the PostHog SDK repo or the local path to the repo.
import PostHog
And run the project.