New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

analytics-client

Package Overview
Dependencies
Maintainers
1
Versions
145
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

analytics-client - npm Package Compare versions

Comparing version 0.7.0-roman-web-e2089b3a99c072bae104dea6543ba889293fa4e9 to 0.7.0-roman-web-fc55c52dde56e624466316893abe22d5d762681b

1

CHANGELOG.md

@@ -10,2 +10,3 @@ # Change Log

* Expose device ID regeneration [Roman Mazur]
* Add user ID and properties interface [Roman Mazur]

@@ -12,0 +13,0 @@

2

dist/package.json
{
"name": "analytics-client",
"version": "0.7.0-roman-web-e2089b3a99c072bae104dea6543ba889293fa4e9",
"version": "0.7.0-roman-web-fc55c52dde56e624466316893abe22d5d762681b",
"description": "Convenient builders to compose analytics tools",

@@ -5,0 +5,0 @@ "repository": {

@@ -13,2 +13,3 @@ import amplitude = require('amplitude-js');

deviceId(): string;
regenerateDeviceId(): void;
linkDevices(userId: string, deviceIds: string[]): void;

@@ -15,0 +16,0 @@ track(eventType: string, props?: Properties): void;

@@ -58,2 +58,5 @@ "use strict";

};
DefaultClient.prototype.regenerateDeviceId = function () {
this.amplitudeInstance.regenerateDeviceId();
};
DefaultClient.prototype.linkDevices = function (userId, deviceIds) {

@@ -60,0 +63,0 @@ var originalDeviceId = this.deviceId();

@@ -10,2 +10,8 @@ "use strict";

expect(client.deviceId()).toBeTruthy();
var callsCount = 0;
client.amplitude().regenerateDeviceId = function () {
callsCount++;
};
client.regenerateDeviceId();
expect(callsCount).toBe(1);
});

@@ -12,0 +18,0 @@ test('device linking', function () {

{
"name": "analytics-client",
"version": "0.7.0-roman-web-e2089b3a99c072bae104dea6543ba889293fa4e9",
"version": "0.7.0-roman-web-fc55c52dde56e624466316893abe22d5d762681b",
"description": "Convenient builders to compose analytics tools",

@@ -5,0 +5,0 @@ "repository": {

@@ -31,2 +31,5 @@ import amplitude = require('amplitude-js');

/** Generate a new device identifier used for reporting. */
regenerateDeviceId(): void;
/** Associate all input device IDs with a user ID. */

@@ -132,2 +135,6 @@ linkDevices(userId: string, deviceIds: string[]): void;

regenerateDeviceId() {
this.amplitudeInstance.regenerateDeviceId();
}
linkDevices(userId: string, deviceIds: string[]): void {

@@ -134,0 +141,0 @@ const originalDeviceId = this.deviceId();

@@ -9,2 +9,9 @@ import { createClient } from '../src/client';

expect(client.deviceId()).toBeTruthy();
let callsCount = 0;
client.amplitude().regenerateDeviceId = () => {
callsCount++;
};
client.regenerateDeviceId();
expect(callsCount).toBe(1);
});

@@ -11,0 +18,0 @@

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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