xamarin-forms-analytics-wrapper
0.2.0
dotnet add package xamarin-forms-analytics-wrapper --version 0.2.0
NuGet\Install-Package xamarin-forms-analytics-wrapper -Version 0.2.0
<PackageReference Include="xamarin-forms-analytics-wrapper" Version="0.2.0" />
paket add xamarin-forms-analytics-wrapper --version 0.2.0
#r "nuget: xamarin-forms-analytics-wrapper, 0.2.0"
// Install xamarin-forms-analytics-wrapper as a Cake Addin #addin nuget:?package=xamarin-forms-analytics-wrapper&version=0.2.0 // Install xamarin-forms-analytics-wrapper as a Cake Tool #tool nuget:?package=xamarin-forms-analytics-wrapper&version=0.2.0
xamarin-forms-analytics-wrapper
##What is this? xamarin-forms-analytics-wrapper is a library which warps Google Analytics tracking to Xamarin.Forms.
I'm very eager about your feedback, so do not hesitate to create an issue or feel free to improve my code via a contribution.
###Setup and Usage
- Install the package via nuget into your PCL and platform specific projects.
- Get your Analytics-Id (iOS AppDelegate.cs, Android: MainActivity.cs)
- Add the registration call to your platform specific main class (see sample).
Example Android implementation of the Init call:
protected override void OnCreate(Bundle bundle)
{
base.OnCreate(bundle);
Forms.Init(this, bundle);
var gaService = AnalyticsService.GetGASInstance();
gaService.Init("UA-12345675-1", this, 3);
gaService.OptOut = false;
}
Example iOS implementation of the Init call:
public override bool FinishedLaunching(UIApplication uiApplication, NSDictionary launchOptions)
{
Forms.Init();
var gaService = AnalyticsService.GetGASInstance();
gaService.Init("UA-12345675-2", 3);
gaService.OptOut = false;
}
More examples on my blog.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
MonoAndroid | monoandroid10 is compatible. |
Xamarin.iOS | xamarinios10 is compatible. |
-
All Frameworks
- Xamarin.Forms (>= 3.0.0.482510)
-
MonoAndroid 1.0
- Xamarin.GooglePlayServices.Analytics (= 60.1142.1)
- Xamarin.GooglePlayServices.Base (= 60.1142.1)
-
Xamarin.iOS 0.0
- Xamarin.Google.iOS.Analytics (= 3.17.0.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
0.2.0:
* update sample and library to Xamarin.Forms to 3.0.0.482510
* update Google.Analytics to 3.17.0.2 on iOS
* update Xamarin.GooglePlayServices.Analytics to 60.11.42.1 on Android
* set iOS Sample to x68_64
* set Android Target to 8.1
0.1.1:
* Change: fix iOS timing tracking
0.1.0:
* Change: Initial release