@scalebun/react-native 1.3.0 → 1.3.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/scalebun.full.js +7 -2
- package/dist/scalebun.full.js.map +1 -1
- package/dist/scalebun.slim.js +7 -2
- package/dist/scalebun.slim.js.map +1 -1
- package/lib/commonjs/features/replay/integrations/logs/consoleIntegration.js +19 -0
- package/lib/commonjs/features/replay/integrations/logs/consoleIntegration.js.map +1 -1
- package/lib/commonjs/features/session/SessionManager.js +7 -1
- package/lib/commonjs/features/session/SessionManager.js.map +1 -1
- package/lib/module/features/replay/integrations/logs/consoleIntegration.js +19 -0
- package/lib/module/features/replay/integrations/logs/consoleIntegration.js.map +1 -1
- package/lib/module/features/session/SessionManager.js +7 -1
- package/lib/module/features/session/SessionManager.js.map +1 -1
- package/lib/typescript/features/replay/integrations/logs/consoleIntegration.d.ts.map +1 -1
- package/lib/typescript/features/session/SessionManager.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/features/replay/integrations/logs/consoleIntegration.ts +20 -0
- package/src/features/session/SessionManager.ts +7 -1
package/dist/scalebun.full.js
CHANGED
|
@@ -6105,7 +6105,7 @@ var init_SessionManager = __esm({
|
|
|
6105
6105
|
confidence: p.confidence ?? null,
|
|
6106
6106
|
source: p.source ?? null
|
|
6107
6107
|
};
|
|
6108
|
-
console.log("[TapDiag]", JSON.stringify(diag));
|
|
6108
|
+
if (__DEV__) console.log("[TapDiag]", JSON.stringify(diag));
|
|
6109
6109
|
} catch {
|
|
6110
6110
|
}
|
|
6111
6111
|
}
|
|
@@ -6362,6 +6362,9 @@ var init_SessionManager = __esm({
|
|
|
6362
6362
|
});
|
|
6363
6363
|
|
|
6364
6364
|
// lib/module/features/replay/integrations/logs/consoleIntegration.js
|
|
6365
|
+
function isSdkInternalLog(firstArg) {
|
|
6366
|
+
return typeof firstArg === "string" && SDK_INTERNAL_LOG_PREFIXES.some((prefix) => firstArg.startsWith(prefix));
|
|
6367
|
+
}
|
|
6365
6368
|
function forwardToLogsLane(method, message) {
|
|
6366
6369
|
try {
|
|
6367
6370
|
const transport = SessionManager.getExistingInstance()?.getBackendTransport();
|
|
@@ -6386,6 +6389,7 @@ function installConsoleIntegration() {
|
|
|
6386
6389
|
const firstArg = args[0];
|
|
6387
6390
|
if (typeof firstArg === "string" && firstArg.startsWith("[ReplaySdk]")) return;
|
|
6388
6391
|
original.apply(console, args);
|
|
6392
|
+
if (isSdkInternalLog(firstArg)) return;
|
|
6389
6393
|
if (_enabled) {
|
|
6390
6394
|
try {
|
|
6391
6395
|
const message = args.map((a) => {
|
|
@@ -6418,7 +6422,7 @@ function uninstallConsoleIntegration() {
|
|
|
6418
6422
|
function setConsoleEnabled(enabled) {
|
|
6419
6423
|
_enabled = enabled;
|
|
6420
6424
|
}
|
|
6421
|
-
var _installed, _enabled, CONSOLE_LEVEL, _originals;
|
|
6425
|
+
var _installed, _enabled, CONSOLE_LEVEL, SDK_INTERNAL_LOG_PREFIXES, _originals;
|
|
6422
6426
|
var init_consoleIntegration = __esm({
|
|
6423
6427
|
"lib/module/features/replay/integrations/logs/consoleIntegration.js"() {
|
|
6424
6428
|
"use strict";
|
|
@@ -6433,6 +6437,7 @@ var init_consoleIntegration = __esm({
|
|
|
6433
6437
|
error: "error",
|
|
6434
6438
|
debug: "debug"
|
|
6435
6439
|
};
|
|
6440
|
+
SDK_INTERNAL_LOG_PREFIXES = ["[TapDiag]", "[TapAccuracy]", "[ScaleBun", "[perf."];
|
|
6436
6441
|
_originals = {
|
|
6437
6442
|
log: console.log,
|
|
6438
6443
|
info: console.info,
|