Skip to main content

Installation

This document will guide you through the installation of the Nudge SDK in your iOS application.

Latest Version:

Installing the Package

Swift Package Manager (SPM)

Add the Nudgecore_iOS SDK through Swift Package Manager in Xcode.

Use https://github.com/nudgenow/iOS as the package source.

Initialization

import SwiftUI
import Nudgecore_iOS

@main
struct YourApp: App {

var nudgeLifecycleManager: NudgeInitialise?

init() {
nudgeLifecycleManager = NudgeInitialise(
apiKey: "YOUR_API_KEY",
debugMode: true,
region:Region.IN or Region.US
)
}

var body: some Scene {
WindowGroup {
ContentView()
}
}
}