@source4society/react-scepter-mobile-gtm-component
v1.0.2
Published
A simple Google Tag Manager component for mobile
Downloads
7
Readme
react-scepter-mobile-gtm-component
A simple Google Tag Manager component for react-native
Installation
npm install @source4society/react-scepter-web-gtm-component
or
yarn add @source4society/react-scepter-web-gtm-component
Then you must remember to run react-native link react-native-google-analytics-bridge
(see react-native-google-anlytics-bridge for more information)
Usage
Add this component to your mobile application to load a GTM container on mount. Example usage:
<GTMComponent containerId={'GTM-XXXXXXX'} />
where containerId is the ID of your GTM container. You will then be able to make subsequent calls with the static GoogleTagManager object from react-native-google-analytics-bridge;