Latest 0.1.0
Homepage https://github.com/corlaonline/GATracker
License MIT
Platforms tvos 9.0
Authors

CI Status
Version
License
Platform

GATracker is a simple library that permit to use Google Analytics on tvOS projects

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Requirements

  • tvOS 9.0+
  • Xcode 8.0+

Installation

GATracker is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "GATracker"

Usage

You have simply to setup the tracker with your Google Analytics property id (eg. UA-XXXXXX-XX) preferable in app delegate

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {

    GATracker.setup("UA-XXXXXXXX-X")

    return true
}

After setup you can track ScreenView or Event wherever in your application by calling these simple function from the shared instance of the GATracker

Screen View

GATracker.sharedInstance.screenView(screenName: "YOUR_VIEW",
                                    customParameters: nil)

Event

GATracker.sharedInstance.event(category: "YOUR_CATEGORY",
                               action: "YOUR_ACTION",
                               label: "YOUR_LABEL",
                               customParameters: nil)

Author

corlaonline, [email protected]

License

GATracker is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "GATracker",
    "version": "0.1.0",
    "summary": "Simple library that permit to use Google Analytics on tvOS projects.",
    "description": "Simple library that permit to use Google Analytics on tvOS projects.",
    "homepage": "https://github.com/corlaonline/GATracker",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Alex Corlatti": "[email protected]"
    },
    "source": {
        "git": "https://github.com/corlaonline/GATracker.git",
        "tag": "0.1.0"
    },
    "platforms": {
        "tvos": "9.0"
    },
    "source_files": "GATracker/Classes/**/*",
    "pushed_with_swift_version": "3.0"
}

Pin It on Pinterest

Share This