Skip to content

Instantly share code, notes, and snippets.

@joshschumacher
Created January 8, 2016 22:23
Show Gist options
  • Save joshschumacher/9a6e502ab9d45417d30f to your computer and use it in GitHub Desktop.
Save joshschumacher/9a6e502ab9d45417d30f to your computer and use it in GitHub Desktop.
var appModules = [
'ionic',
'ngCordova'
];
root.Application = angular.module('com.myorg.myapp', appModules)
.run(function($ionicPlatform) {
$ionicPlatform.ready(function() {
// check for the plugin first, to prevent triggering cordova plugin error when you run the application in the browser
if (window.plugins && window.plugins.matPlugin) {
window.plugins.matPlugin.init("your_advertiser_ID", "your_conversion_key");
// Measure initial app open
window.plugins.matPlugin.measureSession();
}
}))
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment