A Flutter plugin to use the Google Analytics for Firebase API.
For Flutter plugins for other Firebase products, see FlutterFire.md.
To use this plugin, add
firebase_analytics as a dependency in your pubspec.yaml file. You must also configure firebase analytics for each platform project: Android and iOS (see the example folder or https://codelabs.developers.google.com/codelabs/flutter-firebase/#4 for step by step details).
PageRoute transitions, add a
FirebaseAnalyticsObserver to the list of
NavigatorObservers on your
Navigator, e.g. if you're using a
FirebaseAnalytics analytics = FirebaseAnalytics(); MaterialApp( home: MyAppHome(), navigatorObservers: [ FirebaseAnalyticsObserver(analytics: analytics), ], );
You can also track transitions within your
PageRoute (e.g. when the user switches from one tab to another) by
RouteAware and subscribing it to
for an example of how to wire that up.
example directory for a complete sample app using Google Analytics for Firebase.
METHODAndroid constant used for
NavigatorObserver) to automatically log
Demonstrates how to use the firebase_analytics plugin.
For help getting started with Flutter, view our online documentation.
Add this to your package's pubspec.yaml file:
dependencies: firebase_analytics: ^1.0.6
You can install packages from the command line:
$ flutter packages get
Alternatively, your editor might support
flutter packages get.
Check the docs for your editor to learn more.
Now in your Dart code, you can use:
|1.0.6||Nov 10, 2018|
|1.0.5||Oct 30, 2018|
|1.0.4||Oct 12, 2018|
|1.0.3||Aug 21, 2018|
|1.0.2||Jul 23, 2018|
|1.0.1||Jun 1, 2018|
|1.0.0||May 21, 2018|
|0.3.3||Apr 18, 2018|
|0.3.1||Apr 11, 2018|
|0.3.0||Mar 9, 2018|
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
We analyzed this package on Dec 5, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:
Detected platforms: Flutter
References Flutter, and has no conflicting libraries.