Skip to content

Ember addon to install and configure GoogleTagManager in your app

License

Notifications You must be signed in to change notification settings

mtoygar/ember-cli-google-tag-manager

Repository files navigation

Ember CLI google-tag-manager

Min Version 1.13.8

Configuration

In config/environment

var ENV = {
  // ...
  googleTagManager: {
    appId: process.env.GOOGLE_TAG_MANAGER_ID,
    gtmAuth: process.env.GOOGLE_TAG_MANAGER_AUTH, // optional
    gtmPreview: process.env.GOOGLE_TAG_MANAGER_PREVIEW // optional
  }
}

Effects

The addon will inject the Google Tag Manager code in your <head> and <body> as specified here: https://developers.google.com/tag-manager/quickstart

Then addon plugs itself on the main router of the application and send a PageView event after each successful transition.

About

Ember addon to install and configure GoogleTagManager in your app

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published