Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do I use angulartics-tealium #1

Open
tw-louie opened this issue Jan 11, 2016 · 2 comments
Open

How do I use angulartics-tealium #1

tw-louie opened this issue Jan 11, 2016 · 2 comments

Comments

@tw-louie
Copy link

Hello,

I want to use the module you have made but am unsure how to import it. If I had the following code would I have to remove angulartics and angulartics.google.tagmanager in lieu of angulartics.tealium?

import angular from 'angular'
import 'angulartics'
import 'angular-ui-bootstrap'
import 'angular-ui-router'
import appointmentConfirmation from './appointment_confirmation/appointmentConfirmation.module'
import demographics from './demographics/demographics.module'
import error from './error/error.module'
import filters from './filters/filters.module'
import timeslots from './timeslots/timeslots.module'
import { environment } from './environment'

let app = angular.module('Retail', [
  // Angular modules
  'ui.bootstrap',
  'ui.router',
  // Angulartics
  'angulartics',
  'angulartics.google.tagmanager',
  // Our modules
  appointmentConfirmation.name,
  demographics.name,
  error.name,
  filters.name,
  timeslots.name
]).constant('environment', environment)

Cheers,
prov-louie

@ianhampton
Copy link
Owner

Hi,

Make sure you've placed the angulartics-tealium.js file in the src folder and loaded it in your app (see the example in the samples folder). Then replace angulartics.google.tagmanager with angulartics.tealium, or just add it if you want to continue using GTM.

Hope that helps.

Ian

@AbsoLouie
Copy link

Hey Ian,

Thanks for the information. I wanted to let you know that we had issues using the pageTrack method. In the end we had to modify the module on line 58 from:

window.utag.view(utag_data);
to
window.utag.view(utag_data.page_path);

So that the correct arguments would be sent to utag.view.
Is this a good way to handle this issue?

Cheers,
Louie

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants