angulartics-optimizely
Advanced tools
Comparing version
@@ -21,3 +21,5 @@ 'use strict'; | ||
$analyticsProvider.registerEventTrack(function (eventType, _ref) { | ||
$analyticsProvider.registerEventTrack(function (eventType) { | ||
var _ref = arguments.length <= 1 || arguments[1] === undefined ? {} : arguments[1]; | ||
var revenue = _ref.revenue; | ||
@@ -24,0 +26,0 @@ |
@@ -1,1 +0,1 @@ | ||
"use strict";var AngularticsOptimizelyConfig=["$analyticsProvider",function(e){e.settings.pageTracking.trackRelativePath=!0,window.optimizely=window.optimizely||[];var i=function(e,i){var t=["trackEvent",e.replace(/\s+\|\s+/g,"_").replace(/\W+/g,"X")];i&&t.push({revenue:i}),window.optimizely.push(t)};e.registerPageTrack(function(t,n){e.settings.optimizely&&i(e.settings.optimizely.properties.pageName||t)}),e.registerEventTrack(function(e,t){var n=t.revenue;i(e,n)}),e.registerSetUsername(function(e){return window.optimizely.push(["setUserId",e])})}];angular.module("angulartics.optimizely",["angulartics"]).config(AngularticsOptimizelyConfig),module.exports=AngularticsOptimizelyConfig; | ||
"use strict";var AngularticsOptimizelyConfig=["$analyticsProvider",function(e){e.settings.pageTracking.trackRelativePath=!0,window.optimizely=window.optimizely||[];var i=function(e,i){var t=["trackEvent",e.replace(/\s+\|\s+/g,"_").replace(/\W+/g,"X")];i&&t.push({revenue:i}),window.optimizely.push(t)};e.registerPageTrack(function(t,n){e.settings.optimizely&&i(e.settings.optimizely.properties.pageName||t)}),e.registerEventTrack(function(e){var t=arguments.length<=1||void 0===arguments[1]?{}:arguments[1],n=t.revenue;i(e,n)}),e.registerSetUsername(function(e){return window.optimizely.push(["setUserId",e])})}];angular.module("angulartics.optimizely",["angulartics"]).config(AngularticsOptimizelyConfig),module.exports=AngularticsOptimizelyConfig; |
{ | ||
"name": "angulartics-optimizely", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "An angulartics plugin for optimizely", | ||
@@ -5,0 +5,0 @@ "main": "bundle.js", |
@@ -23,3 +23,3 @@ export default [ | ||
$analyticsProvider.registerEventTrack((eventType, {revenue}) => { | ||
$analyticsProvider.registerEventTrack((eventType, {revenue} = {}) => { | ||
// the only value optimizely will track is revenue | ||
@@ -26,0 +26,0 @@ trackEvent(eventType, revenue) |
6959
2.16%72
1.41%