Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@segment/analytics.js-integration-amplitude

Package Overview
Dependencies
Maintainers
119
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@segment/analytics.js-integration-amplitude - npm Package Compare versions

Comparing version 3.0.1 to 3.1.0

4

HISTORY.md

@@ -0,1 +1,5 @@

# 3.1.0 / 2019-08-09
- Add mapping of non-property fields to event_props.
# 3.0.0 / 2019-06-10

@@ -2,0 +6,0 @@

@@ -52,2 +52,3 @@ 'use strict';

.option('traitsToIncrement', [])
.option('appendFieldsToEventProps', {})
.tag('<script src="' + src + '">'));

@@ -257,2 +258,7 @@

// Append extra fields to event_props
each(function(prop, field) {
props[prop] = track.proxy(field);
}, this.options.appendFieldsToEventProps);
// track the event

@@ -259,0 +265,0 @@ if (options.groups) {

4

package.json
{
"name": "@segment/analytics.js-integration-amplitude",
"description": "The Amplitude analytics.js integration.",
"version": "3.0.1",
"version": "3.1.0",
"keywords": [

@@ -53,3 +53,3 @@ "analytics.js",

},
"gitHead": "98db2e118e9764cc61a88e17357e686c640d31a2"
"gitHead": "a582549646b9c88bb628cdb78e9a7d4519589604"
}

@@ -67,2 +67,3 @@ 'use strict';

.option('deviceIdFromUrlParam', false)
.option('appendFieldsToEventProps', {})
);

@@ -637,2 +638,14 @@ });

});
it('should send an event with context properties mapped', function() {
amplitude.options.appendFieldsToEventProps = {
'context.page.path': 'pagePath'
};
analytics.track('event', { foo: 'bar' });
analytics.called(window.amplitude.getInstance().logEvent, 'event', {
foo: 'bar',
pagePath: '/context.html'
});
});
});

@@ -639,0 +652,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc