iOS

In this section, we explain how to get started with the StayTuned SDK for iOS.

Prerequisites

You should use the latest version of Xcode in order to install the SDK.

Make sure that your project meet these requirements:

  • iOS 11.0 or above

  • Xcode 12 or above

  • Swift 4.2 or above

Installation

CocoaPods
Swift Package Manager
CocoaPods
  • If you haven't already, install the latest version of CocoaPods.

  • If you don't have an existing Podfile, run the following command to create one:

Terminal
pod init
  • Add this line to your Podfile:

Podfile
pod 'StayTuned', :git => 'https://github.com/StayTunedAds/staytuned-ios-sdk.git'
  • Do not forget to use the .xcworkspace file to open your project in Xcode, instead of the .xcodeproj file, from here on out.

Swift Package Manager

Once you have your Swift Package set up, adding the StayTunedSDK as a dependency is as easy as adding it to the dependencies value of your Package.swift.

dependencies: [
.package(url: "https://github.com/StayTunedAds/staytuned-ios-sdk", .upToNextMajor(from: "1.0.17"))
]