@devskin/browser-sdk 1.0.13 → 1.0.14

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.
@@ -5568,7 +5568,7 @@
5568
5568
  }
5569
5569
  try {
5570
5570
  console.log('[RRWeb] Starting session recording:', this.sessionId);
5571
- console.log('[RRWeb] SDK Version: 1.0.13');
5571
+ console.log('[RRWeb] SDK Version: 1.0.14');
5572
5572
  this.stopFn = record({
5573
5573
  emit: (event) => {
5574
5574
  // DEBUG: Log ALL event types to diagnose issue
@@ -5757,7 +5757,18 @@
5757
5757
  acc[e.type] = (acc[e.type] || 0) + 1;
5758
5758
  return acc;
5759
5759
  }, {});
5760
+ // Calculate payload size
5761
+ const payload = {
5762
+ session_id: sessionId,
5763
+ events,
5764
+ timestamp: new Date().toISOString(),
5765
+ apiKey: this.config.apiKey,
5766
+ appId: this.config.appId,
5767
+ };
5768
+ const payloadSize = new Blob([JSON.stringify(payload)]).size;
5769
+ const payloadSizeMB = (payloadSize / 1024 / 1024).toFixed(2);
5760
5770
  console.log(`[DevSkin SDK] Sending ${events.length} recording events:`, eventTypes);
5771
+ console.log(`[DevSkin SDK] Payload size: ${payloadSizeMB} MB (${payloadSize} bytes)`);
5761
5772
  console.log(`[DevSkin SDK] First 3 events:`, events.slice(0, 3).map(e => ({ type: e.type, timestamp: e.timestamp })));
5762
5773
  // Check if this batch contains FullSnapshot (type 2)
5763
5774
  const hasFullSnapshot = events.some(e => e.type === 2);