Docs

How to Integrate a SPM Package

Add the Grovs SDK to your iOS project using Swift Package Manager.

Swift Package Manager (SPM) is Apple's official dependency manager built into Xcode. Use it to integrate the Grovs SDK into your project.

Requires Xcode 11 or later. Ensure you have internet access as SPM fetches packages from online repositories.

1

Open your Xcode project

Launch Xcode and open your existing iOS project.

2

Navigate to Package Dependencies

In the Project Navigator, select your project file at the top. Go to the Package Dependencies tab.

3

Add the Grovs package

Click the + button to add a new package dependency. Enter the Grovs repository URL:

https://github.com/grovs-io/grovs-iOS

Click Next to continue.

4

Select the package version

Xcode will fetch the available versions. Choose the latest version from the list and click Next.

5

Add the package to your target

Select the checkbox next to the Grovs package and click Add Package to integrate it into your project.

6

Wait for dependency resolution

Xcode will resolve and download the package dependencies. This may take a few moments depending on your internet connection.

7

Import Grovs in your code

Once the package is integrated, import it in your Swift files:

Swift
import Grovs

Swift Package Manager automatically manages updates. To update to the latest version, right-click the package in the Project Navigator and select Update Package.