Skip to content

Ember addon for integrating Google Tag Manager

License

Notifications You must be signed in to change notification settings

TailorBrands/ember-gtm

Repository files navigation

ember-gtm

Ember addon for integrating Google Tag Manager

Compatibility

  • Ember.js v3.12 or above
  • Ember CLI v2.13 or above
  • Node.js v10 or above

Installation

ember install ember-gtm

Usage

All that's required is setting the GTM key in your config/environment.js file.

// config/environment.js

ENV['ember-gtm'] = {
  appId: '[YOUR_APP_ID]'
};

Then you can use the gtm service freely.

@service gtm;

@action
someAction() {
  const data = {
    something: "for the dataLayer"
  };
  this.gtm.trackGTM(data);
}

Contributing

See the Contributing guide for details.

License

This project is licensed under the MIT License.

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy