mixpanel-browser 2.69.0 → 2.70.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -0
- package/dist/mixpanel-core.cjs.js +14 -10
- package/dist/mixpanel-recorder.js +1 -1
- package/dist/mixpanel-recorder.min.js +1 -1
- package/dist/mixpanel-recorder.min.js.map +1 -1
- package/dist/mixpanel-with-async-recorder.cjs.js +14 -10
- package/dist/mixpanel-with-recorder.js +14 -10
- package/dist/mixpanel-with-recorder.min.js +1 -1
- package/dist/mixpanel.amd.js +14 -10
- package/dist/mixpanel.cjs.js +14 -10
- package/dist/mixpanel.globals.js +14 -10
- package/dist/mixpanel.min.js +82 -81
- package/dist/mixpanel.module.js +14 -10
- package/dist/mixpanel.umd.js +14 -10
- package/package.json +6 -1
- package/src/config.js +1 -1
- package/src/flags/index.js +14 -9
package/dist/mixpanel.amd.js
CHANGED
|
@@ -14041,7 +14041,7 @@ define((function () { 'use strict';
|
|
|
14041
14041
|
|
|
14042
14042
|
var Config = {
|
|
14043
14043
|
DEBUG: false,
|
|
14044
|
-
LIB_VERSION: '2.
|
|
14044
|
+
LIB_VERSION: '2.70.0'
|
|
14045
14045
|
};
|
|
14046
14046
|
|
|
14047
14047
|
/* eslint camelcase: "off", eqeqeq: "off" */
|
|
@@ -18877,17 +18877,21 @@ define((function () { 'use strict';
|
|
|
18877
18877
|
var distinctId = this.getMpProperty('distinct_id');
|
|
18878
18878
|
var deviceId = this.getMpProperty('$device_id');
|
|
18879
18879
|
logger.log('Fetching flags for distinct ID: ' + distinctId);
|
|
18880
|
-
|
|
18881
|
-
|
|
18882
|
-
|
|
18880
|
+
|
|
18881
|
+
var context = _.extend({'distinct_id': distinctId, 'device_id': deviceId}, this.getConfig(CONFIG_CONTEXT));
|
|
18882
|
+
var searchParams = new URLSearchParams();
|
|
18883
|
+
searchParams.set('context', JSON.stringify(context));
|
|
18884
|
+
searchParams.set('token', this.getMpConfig('token'));
|
|
18885
|
+
searchParams.set('mp_lib', 'web');
|
|
18886
|
+
searchParams.set('$lib_version', Config.LIB_VERSION);
|
|
18887
|
+
var url = this.getFullApiRoute() + '?' + searchParams.toString();
|
|
18888
|
+
|
|
18883
18889
|
this._fetchInProgressStartTime = Date.now();
|
|
18884
|
-
this.fetchPromise = win['fetch'](
|
|
18885
|
-
'method': '
|
|
18890
|
+
this.fetchPromise = win['fetch'](url, {
|
|
18891
|
+
'method': 'GET',
|
|
18886
18892
|
'headers': {
|
|
18887
|
-
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
18888
|
-
|
|
18889
|
-
},
|
|
18890
|
-
'body': JSON.stringify(reqParams)
|
|
18893
|
+
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
18894
|
+
}
|
|
18891
18895
|
}).then(function(response) {
|
|
18892
18896
|
this.markFetchComplete();
|
|
18893
18897
|
return response.json().then(function(responseBody) {
|
package/dist/mixpanel.cjs.js
CHANGED
|
@@ -14041,7 +14041,7 @@ if (typeof Promise !== 'undefined' && Promise.toString().indexOf('[native code]'
|
|
|
14041
14041
|
|
|
14042
14042
|
var Config = {
|
|
14043
14043
|
DEBUG: false,
|
|
14044
|
-
LIB_VERSION: '2.
|
|
14044
|
+
LIB_VERSION: '2.70.0'
|
|
14045
14045
|
};
|
|
14046
14046
|
|
|
14047
14047
|
/* eslint camelcase: "off", eqeqeq: "off" */
|
|
@@ -18877,17 +18877,21 @@ FeatureFlagManager.prototype.fetchFlags = function() {
|
|
|
18877
18877
|
var distinctId = this.getMpProperty('distinct_id');
|
|
18878
18878
|
var deviceId = this.getMpProperty('$device_id');
|
|
18879
18879
|
logger.log('Fetching flags for distinct ID: ' + distinctId);
|
|
18880
|
-
|
|
18881
|
-
|
|
18882
|
-
|
|
18880
|
+
|
|
18881
|
+
var context = _.extend({'distinct_id': distinctId, 'device_id': deviceId}, this.getConfig(CONFIG_CONTEXT));
|
|
18882
|
+
var searchParams = new URLSearchParams();
|
|
18883
|
+
searchParams.set('context', JSON.stringify(context));
|
|
18884
|
+
searchParams.set('token', this.getMpConfig('token'));
|
|
18885
|
+
searchParams.set('mp_lib', 'web');
|
|
18886
|
+
searchParams.set('$lib_version', Config.LIB_VERSION);
|
|
18887
|
+
var url = this.getFullApiRoute() + '?' + searchParams.toString();
|
|
18888
|
+
|
|
18883
18889
|
this._fetchInProgressStartTime = Date.now();
|
|
18884
|
-
this.fetchPromise = win['fetch'](
|
|
18885
|
-
'method': '
|
|
18890
|
+
this.fetchPromise = win['fetch'](url, {
|
|
18891
|
+
'method': 'GET',
|
|
18886
18892
|
'headers': {
|
|
18887
|
-
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
18888
|
-
|
|
18889
|
-
},
|
|
18890
|
-
'body': JSON.stringify(reqParams)
|
|
18893
|
+
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
18894
|
+
}
|
|
18891
18895
|
}).then(function(response) {
|
|
18892
18896
|
this.markFetchComplete();
|
|
18893
18897
|
return response.json().then(function(responseBody) {
|
package/dist/mixpanel.globals.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
var Config = {
|
|
5
5
|
DEBUG: false,
|
|
6
|
-
LIB_VERSION: '2.
|
|
6
|
+
LIB_VERSION: '2.70.0'
|
|
7
7
|
};
|
|
8
8
|
|
|
9
9
|
// since es6 imports are static and we run unit tests from the console, window won't be defined when importing this file
|
|
@@ -3164,17 +3164,21 @@
|
|
|
3164
3164
|
var distinctId = this.getMpProperty('distinct_id');
|
|
3165
3165
|
var deviceId = this.getMpProperty('$device_id');
|
|
3166
3166
|
logger$3.log('Fetching flags for distinct ID: ' + distinctId);
|
|
3167
|
-
|
|
3168
|
-
|
|
3169
|
-
|
|
3167
|
+
|
|
3168
|
+
var context = _.extend({'distinct_id': distinctId, 'device_id': deviceId}, this.getConfig(CONFIG_CONTEXT));
|
|
3169
|
+
var searchParams = new URLSearchParams();
|
|
3170
|
+
searchParams.set('context', JSON.stringify(context));
|
|
3171
|
+
searchParams.set('token', this.getMpConfig('token'));
|
|
3172
|
+
searchParams.set('mp_lib', 'web');
|
|
3173
|
+
searchParams.set('$lib_version', Config.LIB_VERSION);
|
|
3174
|
+
var url = this.getFullApiRoute() + '?' + searchParams.toString();
|
|
3175
|
+
|
|
3170
3176
|
this._fetchInProgressStartTime = Date.now();
|
|
3171
|
-
this.fetchPromise = win['fetch'](
|
|
3172
|
-
'method': '
|
|
3177
|
+
this.fetchPromise = win['fetch'](url, {
|
|
3178
|
+
'method': 'GET',
|
|
3173
3179
|
'headers': {
|
|
3174
|
-
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
3175
|
-
|
|
3176
|
-
},
|
|
3177
|
-
'body': JSON.stringify(reqParams)
|
|
3180
|
+
'Authorization': 'Basic ' + btoa(this.getMpConfig('token') + ':')
|
|
3181
|
+
}
|
|
3178
3182
|
}).then(function(response) {
|
|
3179
3183
|
this.markFetchComplete();
|
|
3180
3184
|
return response.json().then(function(responseBody) {
|