@scalebun/react-native 1.2.3 → 1.3.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/dist/scalebun.full.js +35 -1
- package/dist/scalebun.full.js.map +1 -1
- package/dist/scalebun.slim.js +35 -1
- package/dist/scalebun.slim.js.map +1 -1
- package/lib/commonjs/bootstrap/SDKBootstrapper.js +12 -0
- package/lib/commonjs/bootstrap/SDKBootstrapper.js.map +1 -1
- package/lib/commonjs/core/config/schema.js +6 -0
- package/lib/commonjs/core/config/schema.js.map +1 -1
- package/lib/commonjs/public/ScaleBunFacade.js +21 -1
- package/lib/commonjs/public/ScaleBunFacade.js.map +1 -1
- package/lib/module/bootstrap/SDKBootstrapper.js +12 -0
- package/lib/module/bootstrap/SDKBootstrapper.js.map +1 -1
- package/lib/module/core/config/schema.js +6 -0
- package/lib/module/core/config/schema.js.map +1 -1
- package/lib/module/public/ScaleBunFacade.js +21 -1
- package/lib/module/public/ScaleBunFacade.js.map +1 -1
- package/lib/typescript/bootstrap/SDKBootstrapper.d.ts.map +1 -1
- package/lib/typescript/core/config/schema.d.ts +2 -0
- package/lib/typescript/core/config/schema.d.ts.map +1 -1
- package/lib/typescript/public/ScaleBunFacade.d.ts +8 -1
- package/lib/typescript/public/ScaleBunFacade.d.ts.map +1 -1
- package/lib/typescript/public/types.d.ts +12 -0
- package/lib/typescript/public/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/bootstrap/SDKBootstrapper.ts +12 -0
- package/src/core/config/schema.ts +8 -0
- package/src/public/ScaleBunFacade.ts +19 -1
- package/src/public/types.ts +13 -0
package/dist/scalebun.slim.js
CHANGED
|
@@ -9419,6 +9419,12 @@ var SHAPE = {
|
|
|
9419
9419
|
}
|
|
9420
9420
|
},
|
|
9421
9421
|
captureInteractionHeatmap: bool(true),
|
|
9422
|
+
// Opt-in: intercept console.* and ship the lines to the Diagnose → Logs lane in SaaS
|
|
9423
|
+
// mode. OFF by default — console output can carry PII/secrets and adds ingest volume,
|
|
9424
|
+
// so capturing it is the host's explicit choice, not a silent default. When true and a
|
|
9425
|
+
// clientKey is present, the bootstrapper arms the console integration (previously only
|
|
9426
|
+
// reachable through the desktop-debug tooling, so stock SaaS apps captured nothing).
|
|
9427
|
+
captureConsoleLogs: bool(false),
|
|
9422
9428
|
ota: {
|
|
9423
9429
|
kind: "obj",
|
|
9424
9430
|
opt: true,
|
|
@@ -12082,6 +12088,9 @@ function uninstallAlertInstrumentation() {
|
|
|
12082
12088
|
installed = false;
|
|
12083
12089
|
}
|
|
12084
12090
|
|
|
12091
|
+
// lib/module/bootstrap/SDKBootstrapper.js
|
|
12092
|
+
init_consoleIntegration();
|
|
12093
|
+
|
|
12085
12094
|
// lib/module/features/session/BackendSessionAdapter.js
|
|
12086
12095
|
init_internalLogger();
|
|
12087
12096
|
|
|
@@ -13594,6 +13603,9 @@ var SDKBootstrapper = class {
|
|
|
13594
13603
|
}
|
|
13595
13604
|
});
|
|
13596
13605
|
sessionManager.setBackendTransport(backendAdapter);
|
|
13606
|
+
if (this.config.clientKey && this.config.captureConsoleLogs) {
|
|
13607
|
+
installConsoleIntegration();
|
|
13608
|
+
}
|
|
13597
13609
|
backendAdapter.recoverPersistedFrames().catch(() => {
|
|
13598
13610
|
});
|
|
13599
13611
|
if (this.config.clientKey) {
|
|
@@ -13780,6 +13792,7 @@ var SDKBootstrapper = class {
|
|
|
13780
13792
|
this._deepLinkUnsubscribe?.();
|
|
13781
13793
|
this._deepLinkUnsubscribe = null;
|
|
13782
13794
|
uninstallAlertInstrumentation();
|
|
13795
|
+
uninstallConsoleIntegration();
|
|
13783
13796
|
this.featureRegistry.teardownAll();
|
|
13784
13797
|
}
|
|
13785
13798
|
};
|
|
@@ -17119,8 +17132,29 @@ var ScaleBunFacade = class {
|
|
|
17119
17132
|
}
|
|
17120
17133
|
});
|
|
17121
17134
|
}
|
|
17122
|
-
/**
|
|
17135
|
+
/**
|
|
17136
|
+
* Log a message. Delivered to BOTH lanes:
|
|
17137
|
+
* - the Diagnose → Logs lane (tagged `source: 'sdk'`), so an explicit `log()` call shows
|
|
17138
|
+
* up where a developer looks for logs. The method name promised this, but it previously
|
|
17139
|
+
* only emitted a `$log` analytics EVENT and never reached the Logs page.
|
|
17140
|
+
* - the analytics `$log` event (unchanged), so anything already built on it keeps working.
|
|
17141
|
+
* `queueLog` self-gates on `clientKey`, so the Logs-lane write is a no-op outside SaaS mode.
|
|
17142
|
+
*/
|
|
17123
17143
|
log(level, message, data) {
|
|
17144
|
+
try {
|
|
17145
|
+
const transport = SessionManager.getExistingInstance()?.getBackendTransport();
|
|
17146
|
+
transport?.queueLog({
|
|
17147
|
+
level,
|
|
17148
|
+
message,
|
|
17149
|
+
source: "sdk",
|
|
17150
|
+
platform: "js",
|
|
17151
|
+
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
17152
|
+
...data ? {
|
|
17153
|
+
metadata: data
|
|
17154
|
+
} : {}
|
|
17155
|
+
});
|
|
17156
|
+
} catch {
|
|
17157
|
+
}
|
|
17124
17158
|
return this.track("$log", {
|
|
17125
17159
|
level,
|
|
17126
17160
|
message,
|