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

Uncaught module #30

Open
shayzalman opened this issue May 18, 2016 · 2 comments
Open

Uncaught module #30

shayzalman opened this issue May 18, 2016 · 2 comments

Comments

@shayzalman
Copy link

Hi
I followed all the instructions on how to implement the plugin but I always get this error:
[INFO:CONSOLE(59)] "Uncaught module com.jareddickson.cordova.tag-manager.TagManager not found", source: file:///android_asset/www/cordova.js (59)

Do you have any idea what could go wrong?

@froesecom
Copy link

+1 same issue. Did you have any luck Joomi?

@froesecom
Copy link

This turned out to be a configuration error on my part.

The tagManager can't be initialized until the device is ready. In your index.html or whatever:

    document.addEventListener("deviceready", initTagManager, false);
    function initTagManager(){

          var tagManager = window.cordova.require('com.jareddickson.cordova.tag-manager.TagManager');
          var trackingId = 'GTM-CODE';
          var intervalPeriod = 30; 

          // Initialize Tag Manager
          tagManager.init(null, null, trackingId, intervalPeriod);
   }

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

2 participants