@openreplay/tracker 16.0.2 → 16.1.0-beta.1
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/dist/cjs/entry.js +15 -8
- package/dist/cjs/entry.js.map +1 -1
- package/dist/cjs/index.js +15 -8
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/main/modules/attributeSender.d.ts +2 -2
- package/dist/lib/entry.js +15 -8
- package/dist/lib/entry.js.map +1 -1
- package/dist/lib/index.js +15 -8
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/main/modules/attributeSender.d.ts +2 -2
- package/dist/types/main/modules/attributeSender.d.ts +2 -2
- package/package.json +1 -1
package/dist/cjs/entry.js
CHANGED
|
@@ -725,9 +725,7 @@ class StringDictionary {
|
|
|
725
725
|
this.backDict = {};
|
|
726
726
|
this.getKey = (str) => {
|
|
727
727
|
let isNew = false;
|
|
728
|
-
|
|
729
|
-
const safeKey = `__${str}`;
|
|
730
|
-
if (!this.backDict[safeKey]) {
|
|
728
|
+
if (!this.backDict[str]) {
|
|
731
729
|
isNew = true;
|
|
732
730
|
// shaving the first 2 digits of the timestamp (since they are irrelevant for next millennia)
|
|
733
731
|
const shavedTs = Date.now() % 10 ** (13 - 2);
|
|
@@ -739,10 +737,10 @@ class StringDictionary {
|
|
|
739
737
|
else {
|
|
740
738
|
this.lastSuffix = 1;
|
|
741
739
|
}
|
|
742
|
-
this.backDict[
|
|
740
|
+
this.backDict[str] = id;
|
|
743
741
|
this.lastTs = shavedTs;
|
|
744
742
|
}
|
|
745
|
-
return [this.backDict[
|
|
743
|
+
return [this.backDict[str], isNew];
|
|
746
744
|
};
|
|
747
745
|
}
|
|
748
746
|
}
|
|
@@ -4712,7 +4710,7 @@ class App {
|
|
|
4712
4710
|
this.stopCallbacks = [];
|
|
4713
4711
|
this.commitCallbacks = [];
|
|
4714
4712
|
this.activityState = ActivityState.NotActive;
|
|
4715
|
-
this.version = '16.0.
|
|
4713
|
+
this.version = '16.1.0-beta.1'; // TODO: version compatability check inside each plugin.
|
|
4716
4714
|
this.socketMode = false;
|
|
4717
4715
|
this.compressionThreshold = 24 * 1000;
|
|
4718
4716
|
this.bc = null;
|
|
@@ -5347,7 +5345,16 @@ class App {
|
|
|
5347
5345
|
requestIdleCb(() => {
|
|
5348
5346
|
this.messages.unshift(TabData(this.session.getTabId()));
|
|
5349
5347
|
this.messages.unshift(Timestamp(this.timestamp()));
|
|
5350
|
-
|
|
5348
|
+
if (this.messages.length > 3) {
|
|
5349
|
+
console.log(this.messages);
|
|
5350
|
+
}
|
|
5351
|
+
try {
|
|
5352
|
+
this.worker?.postMessage(this.messages);
|
|
5353
|
+
}
|
|
5354
|
+
catch (e) {
|
|
5355
|
+
console.log(this.messages.join(','));
|
|
5356
|
+
console.error(e);
|
|
5357
|
+
}
|
|
5351
5358
|
this.commitCallbacks.forEach((cb) => cb(this.messages));
|
|
5352
5359
|
this.messages.length = 0;
|
|
5353
5360
|
});
|
|
@@ -9175,7 +9182,7 @@ class API {
|
|
|
9175
9182
|
this.signalStartIssue = (reason, missingApi) => {
|
|
9176
9183
|
const doNotTrack = this.checkDoNotTrack();
|
|
9177
9184
|
console.log("Tracker couldn't start due to:", JSON.stringify({
|
|
9178
|
-
trackerVersion: '16.0.
|
|
9185
|
+
trackerVersion: '16.1.0-beta.1',
|
|
9179
9186
|
projectKey: this.options.projectKey,
|
|
9180
9187
|
doNotTrack,
|
|
9181
9188
|
reason: missingApi.length ? `missing api: ${missingApi.join(',')}` : reason,
|