Overview:
The GoogleAnalyticsBridge is a library designed to provide a simple interface to the native Google Analytics libraries on both iOS and Android platforms. It automates metadata handling by the Google Analytics native library, including device UUID, device model, viewport size, and OS version. Although the library is being deprecated in favor of Google Analytics for Firebase, it will continue to receive minor fixes until it is archived in 2019.
Features:
- Native Bridge: Provides access to Google Analytics native libraries on both iOS and Android platforms.
- Automated Metadata Handling: Handles metadata such as device UUID, device model, viewport size, and OS version automatically.
- Easy Tracking: Only requires sending a few parameters when tracking events.
Installation:
To install the GoogleAnalyticsBridge library, follow these steps:
- For React Native >= 0.40, use version 5.0.0 (and newer) of the module. For React Native < 0.40, use version 4.0.3.
- Install the library using npm:
npm install --save react-native-google-analytics-bridgeor using yarn:yarn add react-native-google-analytics-bridge. - Link the library using
react-native link react-native-google-analytics-bridge. - If issues persist post-installation, consult the manual installation guide.
Summary:
The GoogleAnalyticsBridge library serves as a convenient interface to the native Google Analytics libraries on both iOS and Android platforms. Despite being deprecated in light of Google Analytics for Firebase, it continues to provide automated metadata handling and streamlined event tracking functionalities. Installation involves using npm or yarn to install the library and linking it to the project. For React Native versions older than 0.40, specific versions of the library need to be utilized.