Swiftpack.co - GroupeMINASTE/DigiAnalytics as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by GroupeMINASTE.
GroupeMINASTE/DigiAnalytics 1.0.3
Realtime web analytics with privacy and simplicity at its core.
⭐️ 0
🕓 1 year ago
.package(url: "https://github.com/GroupeMINASTE/DigiAnalytics.git", from: "1.0.3")

DigiAnalytics

License Issues Pull Requests Code Size

Realtime web analytics with privacy and simplicity at its core.

Register your app

Go to https://digianalytics.fr/websites/new to register your app.

You need to choose a domain name or subdomain to associate your app with. In this example, we will use https://app.example.com/ as website URL.

Installation

iOS

Add https://github.com/GroupeMINASTE/DigiAnalytics.git to your Swift Package configuration (or using the Xcode menu: File > Swift Packages > Add Package Dependency)

Android

Add the following to your build.gradle file:

repositories {
    mavenCentral()
}

dependencies {
    implementation 'me.nathanfallet.digianalytics:digianalytics:1.0.1'
}

Usage

iOS

Setup a shared instance of your analytics object:

import DigiAnalytics

extension DigiAnalytics {

    static let shared = DigiAnalytics(baseURL: "https://app.example.com/")

}

Then, send requests where you want to get analytics (e.g. in a view controller viewDidAppear(_:))

// Will appear on dashbord as `https://app.example.com/home`
DigiAnalytics.shared.send(path: "home")

Android

Setup a shared instance of your analytics object:

val analytics = DigiAnalytics("https://app.example.com/")

Then, send requests where you want to get analytics (e.g. in an activity onResume())

// Will appear on dashbord as `https://app.example.com/home`
analytics.send("home", this)

GitHub

link
Stars: 0
Last commit: 3 weeks ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Release Notes

DigiAnalytics Package v1.0.3
1 year ago

Adding support for watchOS

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics