gtagger

1.0.1 • Public • Published

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 --save

Initialize 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

Andrey Feelashov

License

This project is licensed under the MIT License.

/gtagger/

    Package Sidebar

    Install

    npm i gtagger

    Weekly Downloads

    1

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    6.16 kB

    Total Files

    5

    Last publish

    Collaborators

    • andreyfeelashov