gtagger
v1.0.1
Published
An importable Global Site Tag wrapper for Google website tracking.
Maintainers
Readme
gtagger
An importable Global Site Tag wrapper for Google website tracking. Allows bundling gtag.js code snippet alongside other modules.
Usage
Install with npm:
npm install gtagger --saveInitialize using a specific tracking ID:
import { Gtagger } from 'gtagger';
Gtagger.initialize(trackingId);Run commands the same way you would with gtag directly:
Gtagger.run(commandType, ...commandParameters);Note that calling Gtagger.run without initializing first will likely (and definitely should) fail.
Author
License
This project is licensed under the MIT License.
