@scalebun/react-native 1.0.4 → 1.2.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/android/src/main/java/com/scalebun/rn/ota/SlotManager.kt +70 -4
- package/dist/scalebun.full.js +33132 -0
- package/dist/scalebun.full.js.map +1 -0
- package/dist/scalebun.slim.js +29930 -0
- package/dist/scalebun.slim.js.map +1 -0
- package/lib/commonjs/bootstrap/FeatureRegistry.js +4 -4
- package/lib/commonjs/bootstrap/FeatureRegistry.js.map +1 -1
- package/lib/commonjs/bootstrap/SDKBootstrapper.js +20 -17
- package/lib/commonjs/bootstrap/SDKBootstrapper.js.map +1 -1
- package/lib/commonjs/compat/codepush.js +78 -15
- package/lib/commonjs/compat/codepush.js.map +1 -1
- package/lib/commonjs/core/config/schema.js +412 -219
- package/lib/commonjs/core/config/schema.js.map +1 -1
- package/lib/commonjs/core/constants/endpoints.js +9 -6
- package/lib/commonjs/core/constants/endpoints.js.map +1 -1
- package/lib/commonjs/core/constants/protocol.js +31 -0
- package/lib/commonjs/core/constants/protocol.js.map +1 -0
- package/lib/commonjs/core/constants/timings.js +4 -1
- package/lib/commonjs/core/constants/timings.js.map +1 -1
- package/lib/commonjs/core/lifecycle/appLifecycle.js +1 -1
- package/lib/commonjs/core/lifecycle/appLifecycle.js.map +1 -1
- package/lib/commonjs/debug/bootstrap.js +30 -10
- package/lib/commonjs/debug/bootstrap.js.map +1 -1
- package/lib/commonjs/debug/exportBridge.js +5 -3
- package/lib/commonjs/debug/exportBridge.js.map +1 -1
- package/lib/commonjs/debug/hostResolver.js +2 -2
- package/lib/commonjs/debug/hostResolver.js.map +1 -1
- package/lib/commonjs/debug/perfWiring.js +4 -4
- package/lib/commonjs/debug/perfWiring.js.map +1 -1
- package/lib/commonjs/debug/replayWiring.js +5 -5
- package/lib/commonjs/debug/replayWiring.js.map +1 -1
- package/lib/commonjs/debug/screenTracking.js +2 -2
- package/lib/commonjs/debug/screenTracking.js.map +1 -1
- package/lib/commonjs/debug/sessionWiring.js +2 -2
- package/lib/commonjs/debug/sessionWiring.js.map +1 -1
- package/lib/commonjs/features/crash/NativeCrashFeature.js +1 -1
- package/lib/commonjs/features/crash/NativeCrashFeature.js.map +1 -1
- package/lib/commonjs/features/crash/globalHandler.js +3 -3
- package/lib/commonjs/features/crash/globalHandler.js.map +1 -1
- package/lib/commonjs/features/crash/nativeCrashBridge.js +7 -7
- package/lib/commonjs/features/crash/nativeCrashBridge.js.map +1 -1
- package/lib/commonjs/features/crash/rejectionHandler.js +2 -2
- package/lib/commonjs/features/crash/rejectionHandler.js.map +1 -1
- package/lib/commonjs/features/engage/EngageArchetypeRenderers.js +0 -9
- package/lib/commonjs/features/engage/EngageArchetypeRenderers.js.map +1 -1
- package/lib/commonjs/features/engage/EngageInAppView.js +1 -1
- package/lib/commonjs/features/engage/EngageInAppView.js.map +1 -1
- package/lib/commonjs/features/engage/EngagePromptProvider.js +17 -17
- package/lib/commonjs/features/engage/EngagePromptProvider.js.map +1 -1
- package/lib/commonjs/features/engage/EngageTransport.js +5 -5
- package/lib/commonjs/features/engage/EngageTransport.js.map +1 -1
- package/lib/commonjs/features/engage/engagePushTokenBridge.js +4 -4
- package/lib/commonjs/features/engage/engagePushTokenBridge.js.map +1 -1
- package/lib/commonjs/features/engage/engageShakeBridge.js +2 -2
- package/lib/commonjs/features/engage/engageShakeBridge.js.map +1 -1
- package/lib/commonjs/features/engage/engageSignals.js +1 -1
- package/lib/commonjs/features/engage/engageSignals.js.map +1 -1
- package/lib/commonjs/features/engage/engageStoreReviewBridge.js +2 -2
- package/lib/commonjs/features/engage/engageStoreReviewBridge.js.map +1 -1
- package/lib/commonjs/features/engage/engageTestSeenStore.js +1 -1
- package/lib/commonjs/features/engage/engageTestSeenStore.js.map +1 -1
- package/lib/commonjs/features/engage/engageThrottle.js +4 -4
- package/lib/commonjs/features/engage/engageThrottle.js.map +1 -1
- package/lib/commonjs/features/engage/engageTriggerEngine.js +4 -4
- package/lib/commonjs/features/engage/engageTriggerEngine.js.map +1 -1
- package/lib/commonjs/features/engage/engageWindowInsets.js +1 -1
- package/lib/commonjs/features/engage/engageWindowInsets.js.map +1 -1
- package/lib/commonjs/features/install-referrer/installReferrer.js +3 -3
- package/lib/commonjs/features/install-referrer/installReferrer.js.map +1 -1
- package/lib/commonjs/features/journey/calibrationContext.js +0 -9
- package/lib/commonjs/features/journey/calibrationContext.js.map +1 -1
- package/lib/commonjs/features/journey/journeyManager.js +4 -1
- package/lib/commonjs/features/journey/journeyManager.js.map +1 -1
- package/lib/commonjs/features/navigation/AutoScreenDetector.js +4 -4
- package/lib/commonjs/features/navigation/AutoScreenDetector.js.map +1 -1
- package/lib/commonjs/features/ota/OtaOrchestrator.js +27 -18
- package/lib/commonjs/features/ota/OtaOrchestrator.js.map +1 -1
- package/lib/commonjs/features/ota/geoCountry.js +2 -2
- package/lib/commonjs/features/ota/geoCountry.js.map +1 -1
- package/lib/commonjs/features/ota/retry.js +2 -2
- package/lib/commonjs/features/ota/retry.js.map +1 -1
- package/lib/commonjs/features/replay/core/logger/logger.js +0 -4
- package/lib/commonjs/features/replay/core/logger/logger.js.map +1 -1
- package/lib/commonjs/features/replay/integrations/network/networkAdapter.js +1 -54
- package/lib/commonjs/features/replay/integrations/network/networkAdapter.js.map +1 -1
- package/lib/commonjs/features/replay/integrations/react-navigation/navigationIntegration.js +1 -1
- package/lib/commonjs/features/replay/integrations/react-navigation/navigationIntegration.js.map +1 -1
- package/lib/commonjs/features/replay/integrations/touch/ReplayRoot.js +1 -1
- package/lib/commonjs/features/replay/integrations/touch/ReplayRoot.js.map +1 -1
- package/lib/commonjs/features/replay/pipeline/batching/batchManager.js +1 -1
- package/lib/commonjs/features/replay/pipeline/batching/batchManager.js.map +1 -1
- package/lib/commonjs/features/replay/pipeline/retry/retryPolicy.js +1 -1
- package/lib/commonjs/features/replay/pipeline/retry/retryPolicy.js.map +1 -1
- package/lib/commonjs/features/replay/public/api.js +7 -7
- package/lib/commonjs/features/replay/public/api.js.map +1 -1
- package/lib/commonjs/features/replay/replay/session/sessionOrchestrator.js +9 -9
- package/lib/commonjs/features/replay/replay/session/sessionOrchestrator.js.map +1 -1
- package/lib/commonjs/features/session/BackendSessionAdapter.js +41 -41
- package/lib/commonjs/features/session/BackendSessionAdapter.js.map +1 -1
- package/lib/commonjs/features/session/DesktopSessionTransport.js +5 -2
- package/lib/commonjs/features/session/DesktopSessionTransport.js.map +1 -1
- package/lib/commonjs/features/session/JourneyEventPipeline.js +1 -1
- package/lib/commonjs/features/session/JourneyEventPipeline.js.map +1 -1
- package/lib/commonjs/features/session/ReplayCaptureManager.js +14 -14
- package/lib/commonjs/features/session/ReplayCaptureManager.js.map +1 -1
- package/lib/commonjs/features/session/SessionManager.js +9 -9
- package/lib/commonjs/features/session/SessionManager.js.map +1 -1
- package/lib/commonjs/features/session/SyncDecisionEngine.js +1 -1
- package/lib/commonjs/features/session/SyncDecisionEngine.js.map +1 -1
- package/lib/commonjs/features/skan/skanBridge.js +6 -15
- package/lib/commonjs/features/skan/skanBridge.js.map +1 -1
- package/lib/commonjs/features/skan/skanConversionManager.js +5 -5
- package/lib/commonjs/features/skan/skanConversionManager.js.map +1 -1
- package/lib/commonjs/integrations/fetch/fetchInterceptor.js +1 -1
- package/lib/commonjs/integrations/fetch/fetchInterceptor.js.map +1 -1
- package/lib/commonjs/integrations/xhr/xhrInterceptor.js +1 -1
- package/lib/commonjs/integrations/xhr/xhrInterceptor.js.map +1 -1
- package/lib/commonjs/metro/composeSourceMap.js +105 -0
- package/lib/commonjs/metro/composeSourceMap.js.map +1 -0
- package/lib/commonjs/metro/featureModules.js +131 -0
- package/lib/commonjs/metro/featureModules.js.map +1 -0
- package/lib/commonjs/metro/index.js +123 -2
- package/lib/commonjs/metro/index.js.map +1 -1
- package/lib/commonjs/metro/serializerCompose.js +129 -0
- package/lib/commonjs/metro/serializerCompose.js.map +1 -0
- package/lib/commonjs/pipeline/dispatcher/dispatcher.js +1 -1
- package/lib/commonjs/pipeline/dispatcher/dispatcher.js.map +1 -1
- package/lib/commonjs/pipeline/queue/flushQueue.js +2 -2
- package/lib/commonjs/pipeline/queue/flushQueue.js.map +1 -1
- package/lib/commonjs/pipeline/queue/persistentQueue.js +6 -37
- package/lib/commonjs/pipeline/queue/persistentQueue.js.map +1 -1
- package/lib/commonjs/pipeline/scheduler/flushScheduler.js +1 -1
- package/lib/commonjs/pipeline/scheduler/flushScheduler.js.map +1 -1
- package/lib/commonjs/public/ScaleBunFacade.js +64 -15
- package/lib/commonjs/public/ScaleBunFacade.js.map +1 -1
- package/lib/commonjs/push/PushManager.js +3 -3
- package/lib/commonjs/push/PushManager.js.map +1 -1
- package/lib/commonjs/push/adapters/NativeBridgeAdapter.js +1 -1
- package/lib/commonjs/push/adapters/NativeBridgeAdapter.js.map +1 -1
- package/lib/commonjs/push/native/nativeNotifications.js +7 -18
- package/lib/commonjs/push/native/nativeNotifications.js.map +1 -1
- package/lib/commonjs/storage/StorageBackend.js +1 -1
- package/lib/commonjs/storage/StorageBackend.js.map +1 -1
- package/lib/module/bootstrap/FeatureRegistry.js +4 -4
- package/lib/module/bootstrap/FeatureRegistry.js.map +1 -1
- package/lib/module/bootstrap/SDKBootstrapper.js +20 -17
- package/lib/module/bootstrap/SDKBootstrapper.js.map +1 -1
- package/lib/module/compat/codepush.js +77 -14
- package/lib/module/compat/codepush.js.map +1 -1
- package/lib/module/core/config/schema.js +411 -218
- package/lib/module/core/config/schema.js.map +1 -1
- package/lib/module/core/constants/endpoints.js +9 -6
- package/lib/module/core/constants/endpoints.js.map +1 -1
- package/lib/module/core/constants/protocol.js +25 -0
- package/lib/module/core/constants/protocol.js.map +1 -0
- package/lib/module/core/constants/timings.js +3 -1
- package/lib/module/core/constants/timings.js.map +1 -1
- package/lib/module/core/lifecycle/appLifecycle.js +1 -1
- package/lib/module/core/lifecycle/appLifecycle.js.map +1 -1
- package/lib/module/debug/bootstrap.js +30 -9
- package/lib/module/debug/bootstrap.js.map +1 -1
- package/lib/module/debug/exportBridge.js +5 -3
- package/lib/module/debug/exportBridge.js.map +1 -1
- package/lib/module/debug/hostResolver.js +2 -2
- package/lib/module/debug/hostResolver.js.map +1 -1
- package/lib/module/debug/perfWiring.js +4 -4
- package/lib/module/debug/perfWiring.js.map +1 -1
- package/lib/module/debug/replayWiring.js +5 -5
- package/lib/module/debug/replayWiring.js.map +1 -1
- package/lib/module/debug/screenTracking.js +2 -2
- package/lib/module/debug/screenTracking.js.map +1 -1
- package/lib/module/debug/sessionWiring.js +2 -2
- package/lib/module/debug/sessionWiring.js.map +1 -1
- package/lib/module/features/crash/NativeCrashFeature.js +1 -1
- package/lib/module/features/crash/NativeCrashFeature.js.map +1 -1
- package/lib/module/features/crash/globalHandler.js +3 -3
- package/lib/module/features/crash/globalHandler.js.map +1 -1
- package/lib/module/features/crash/nativeCrashBridge.js +7 -7
- package/lib/module/features/crash/nativeCrashBridge.js.map +1 -1
- package/lib/module/features/crash/rejectionHandler.js +2 -2
- package/lib/module/features/crash/rejectionHandler.js.map +1 -1
- package/lib/module/features/engage/EngageArchetypeRenderers.js +0 -8
- package/lib/module/features/engage/EngageArchetypeRenderers.js.map +1 -1
- package/lib/module/features/engage/EngageInAppView.js +1 -1
- package/lib/module/features/engage/EngageInAppView.js.map +1 -1
- package/lib/module/features/engage/EngagePromptProvider.js +17 -17
- package/lib/module/features/engage/EngagePromptProvider.js.map +1 -1
- package/lib/module/features/engage/EngageTransport.js +5 -5
- package/lib/module/features/engage/EngageTransport.js.map +1 -1
- package/lib/module/features/engage/engagePushTokenBridge.js +4 -4
- package/lib/module/features/engage/engagePushTokenBridge.js.map +1 -1
- package/lib/module/features/engage/engageShakeBridge.js +2 -2
- package/lib/module/features/engage/engageShakeBridge.js.map +1 -1
- package/lib/module/features/engage/engageSignals.js +1 -1
- package/lib/module/features/engage/engageSignals.js.map +1 -1
- package/lib/module/features/engage/engageStoreReviewBridge.js +2 -2
- package/lib/module/features/engage/engageStoreReviewBridge.js.map +1 -1
- package/lib/module/features/engage/engageTestSeenStore.js +1 -1
- package/lib/module/features/engage/engageTestSeenStore.js.map +1 -1
- package/lib/module/features/engage/engageThrottle.js +4 -4
- package/lib/module/features/engage/engageThrottle.js.map +1 -1
- package/lib/module/features/engage/engageTriggerEngine.js +4 -4
- package/lib/module/features/engage/engageTriggerEngine.js.map +1 -1
- package/lib/module/features/engage/engageWindowInsets.js +1 -1
- package/lib/module/features/engage/engageWindowInsets.js.map +1 -1
- package/lib/module/features/install-referrer/installReferrer.js +3 -3
- package/lib/module/features/install-referrer/installReferrer.js.map +1 -1
- package/lib/module/features/journey/calibrationContext.js +0 -8
- package/lib/module/features/journey/calibrationContext.js.map +1 -1
- package/lib/module/features/journey/journeyManager.js +3 -1
- package/lib/module/features/journey/journeyManager.js.map +1 -1
- package/lib/module/features/navigation/AutoScreenDetector.js +4 -4
- package/lib/module/features/navigation/AutoScreenDetector.js.map +1 -1
- package/lib/module/features/ota/OtaOrchestrator.js +27 -18
- package/lib/module/features/ota/OtaOrchestrator.js.map +1 -1
- package/lib/module/features/ota/geoCountry.js +2 -2
- package/lib/module/features/ota/geoCountry.js.map +1 -1
- package/lib/module/features/ota/retry.js +2 -2
- package/lib/module/features/ota/retry.js.map +1 -1
- package/lib/module/features/replay/core/logger/logger.js +0 -3
- package/lib/module/features/replay/core/logger/logger.js.map +1 -1
- package/lib/module/features/replay/integrations/network/networkAdapter.js +1 -52
- package/lib/module/features/replay/integrations/network/networkAdapter.js.map +1 -1
- package/lib/module/features/replay/integrations/react-navigation/navigationIntegration.js +1 -1
- package/lib/module/features/replay/integrations/react-navigation/navigationIntegration.js.map +1 -1
- package/lib/module/features/replay/integrations/touch/ReplayRoot.js +1 -1
- package/lib/module/features/replay/integrations/touch/ReplayRoot.js.map +1 -1
- package/lib/module/features/replay/pipeline/batching/batchManager.js +1 -1
- package/lib/module/features/replay/pipeline/batching/batchManager.js.map +1 -1
- package/lib/module/features/replay/pipeline/retry/retryPolicy.js +1 -1
- package/lib/module/features/replay/pipeline/retry/retryPolicy.js.map +1 -1
- package/lib/module/features/replay/public/api.js +7 -7
- package/lib/module/features/replay/public/api.js.map +1 -1
- package/lib/module/features/replay/replay/session/sessionOrchestrator.js +9 -9
- package/lib/module/features/replay/replay/session/sessionOrchestrator.js.map +1 -1
- package/lib/module/features/session/BackendSessionAdapter.js +41 -41
- package/lib/module/features/session/BackendSessionAdapter.js.map +1 -1
- package/lib/module/features/session/DesktopSessionTransport.js +4 -2
- package/lib/module/features/session/DesktopSessionTransport.js.map +1 -1
- package/lib/module/features/session/JourneyEventPipeline.js +1 -1
- package/lib/module/features/session/JourneyEventPipeline.js.map +1 -1
- package/lib/module/features/session/ReplayCaptureManager.js +14 -14
- package/lib/module/features/session/ReplayCaptureManager.js.map +1 -1
- package/lib/module/features/session/SessionManager.js +9 -9
- package/lib/module/features/session/SessionManager.js.map +1 -1
- package/lib/module/features/session/SyncDecisionEngine.js +1 -1
- package/lib/module/features/session/SyncDecisionEngine.js.map +1 -1
- package/lib/module/features/skan/skanBridge.js +6 -14
- package/lib/module/features/skan/skanBridge.js.map +1 -1
- package/lib/module/features/skan/skanConversionManager.js +5 -5
- package/lib/module/features/skan/skanConversionManager.js.map +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/integrations/fetch/fetchInterceptor.js +1 -1
- package/lib/module/integrations/fetch/fetchInterceptor.js.map +1 -1
- package/lib/module/integrations/xhr/xhrInterceptor.js +1 -1
- package/lib/module/integrations/xhr/xhrInterceptor.js.map +1 -1
- package/lib/module/metro/composeSourceMap.js +97 -0
- package/lib/module/metro/composeSourceMap.js.map +1 -0
- package/lib/module/metro/featureModules.js +123 -0
- package/lib/module/metro/featureModules.js.map +1 -0
- package/lib/module/metro/index.js +122 -2
- package/lib/module/metro/index.js.map +1 -1
- package/lib/module/metro/serializerCompose.js +120 -0
- package/lib/module/metro/serializerCompose.js.map +1 -0
- package/lib/module/pipeline/dispatcher/dispatcher.js +1 -1
- package/lib/module/pipeline/dispatcher/dispatcher.js.map +1 -1
- package/lib/module/pipeline/queue/flushQueue.js +2 -2
- package/lib/module/pipeline/queue/flushQueue.js.map +1 -1
- package/lib/module/pipeline/queue/persistentQueue.js +6 -36
- package/lib/module/pipeline/queue/persistentQueue.js.map +1 -1
- package/lib/module/pipeline/scheduler/flushScheduler.js +1 -1
- package/lib/module/pipeline/scheduler/flushScheduler.js.map +1 -1
- package/lib/module/public/ScaleBunFacade.js +64 -15
- package/lib/module/public/ScaleBunFacade.js.map +1 -1
- package/lib/module/push/PushManager.js +3 -3
- package/lib/module/push/PushManager.js.map +1 -1
- package/lib/module/push/adapters/NativeBridgeAdapter.js +1 -1
- package/lib/module/push/adapters/NativeBridgeAdapter.js.map +1 -1
- package/lib/module/push/native/nativeNotifications.js +7 -17
- package/lib/module/push/native/nativeNotifications.js.map +1 -1
- package/lib/module/storage/StorageBackend.js +1 -1
- package/lib/module/storage/StorageBackend.js.map +1 -1
- package/lib/typescript/bootstrap/SDKBootstrapper.d.ts.map +1 -1
- package/lib/typescript/compat/codepush.d.ts +27 -4
- package/lib/typescript/compat/codepush.d.ts.map +1 -1
- package/lib/typescript/core/config/schema.d.ts +61 -37
- package/lib/typescript/core/config/schema.d.ts.map +1 -1
- package/lib/typescript/core/constants/endpoints.d.ts +9 -6
- package/lib/typescript/core/constants/endpoints.d.ts.map +1 -1
- package/lib/typescript/core/constants/protocol.d.ts +23 -0
- package/lib/typescript/core/constants/protocol.d.ts.map +1 -0
- package/lib/typescript/core/constants/timings.d.ts +1 -1
- package/lib/typescript/core/constants/timings.d.ts.map +1 -1
- package/lib/typescript/debug/bootstrap.d.ts +0 -1
- package/lib/typescript/debug/bootstrap.d.ts.map +1 -1
- package/lib/typescript/debug/exportBridge.d.ts.map +1 -1
- package/lib/typescript/features/engage/EngageArchetypeRenderers.d.ts +0 -2
- package/lib/typescript/features/engage/EngageArchetypeRenderers.d.ts.map +1 -1
- package/lib/typescript/features/engage/EngageTransport.d.ts +1 -1
- package/lib/typescript/features/engage/EngageTransport.d.ts.map +1 -1
- package/lib/typescript/features/journey/calibrationContext.d.ts +0 -1
- package/lib/typescript/features/journey/calibrationContext.d.ts.map +1 -1
- package/lib/typescript/features/journey/journeyManager.d.ts.map +1 -1
- package/lib/typescript/features/ota/OtaOrchestrator.d.ts +6 -0
- package/lib/typescript/features/ota/OtaOrchestrator.d.ts.map +1 -1
- package/lib/typescript/features/replay/core/logger/logger.d.ts +0 -1
- package/lib/typescript/features/replay/core/logger/logger.d.ts.map +1 -1
- package/lib/typescript/features/replay/integrations/network/networkAdapter.d.ts +0 -10
- package/lib/typescript/features/replay/integrations/network/networkAdapter.d.ts.map +1 -1
- package/lib/typescript/features/session/DesktopSessionTransport.d.ts.map +1 -1
- package/lib/typescript/features/skan/skanBridge.d.ts +0 -2
- package/lib/typescript/features/skan/skanBridge.d.ts.map +1 -1
- package/lib/typescript/metro/composeSourceMap.d.ts +26 -0
- package/lib/typescript/metro/composeSourceMap.d.ts.map +1 -0
- package/lib/typescript/metro/featureModules.d.ts +49 -0
- package/lib/typescript/metro/featureModules.d.ts.map +1 -0
- package/lib/typescript/metro/index.d.ts +22 -0
- package/lib/typescript/metro/index.d.ts.map +1 -1
- package/lib/typescript/metro/serializerCompose.d.ts +46 -0
- package/lib/typescript/metro/serializerCompose.d.ts.map +1 -0
- package/lib/typescript/pipeline/queue/persistentQueue.d.ts +0 -10
- package/lib/typescript/pipeline/queue/persistentQueue.d.ts.map +1 -1
- package/lib/typescript/public/ScaleBunFacade.d.ts +11 -0
- package/lib/typescript/public/ScaleBunFacade.d.ts.map +1 -1
- package/lib/typescript/public/types.d.ts +34 -8
- package/lib/typescript/public/types.d.ts.map +1 -1
- package/lib/typescript/push/native/nativeNotifications.d.ts +0 -6
- package/lib/typescript/push/native/nativeNotifications.d.ts.map +1 -1
- package/package.json +15 -11
- package/src/bootstrap/FeatureRegistry.ts +4 -4
- package/src/bootstrap/SDKBootstrapper.ts +20 -17
- package/src/compat/codepush.ts +87 -16
- package/src/core/config/schema.ts +353 -222
- package/src/core/constants/endpoints.ts +9 -6
- package/src/core/constants/protocol.ts +24 -0
- package/src/core/constants/timings.ts +3 -1
- package/src/core/lifecycle/appLifecycle.ts +1 -1
- package/src/debug/bootstrap.ts +40 -7
- package/src/debug/exportBridge.ts +5 -3
- package/src/debug/hostResolver.ts +2 -2
- package/src/debug/perfWiring.ts +4 -4
- package/src/debug/replayWiring.ts +5 -5
- package/src/debug/screenTracking.ts +2 -2
- package/src/debug/sessionWiring.ts +2 -2
- package/src/features/crash/NativeCrashFeature.ts +1 -1
- package/src/features/crash/globalHandler.ts +3 -3
- package/src/features/crash/nativeCrashBridge.ts +7 -7
- package/src/features/crash/rejectionHandler.ts +2 -2
- package/src/features/engage/EngageArchetypeRenderers.tsx +0 -11
- package/src/features/engage/EngageInAppView.tsx +1 -1
- package/src/features/engage/EngagePromptProvider.tsx +17 -17
- package/src/features/engage/EngageTransport.ts +6 -6
- package/src/features/engage/engagePushTokenBridge.ts +4 -4
- package/src/features/engage/engageShakeBridge.ts +2 -2
- package/src/features/engage/engageSignals.ts +1 -1
- package/src/features/engage/engageStoreReviewBridge.ts +2 -2
- package/src/features/engage/engageTestSeenStore.ts +1 -1
- package/src/features/engage/engageThrottle.ts +4 -4
- package/src/features/engage/engageTriggerEngine.ts +4 -4
- package/src/features/engage/engageWindowInsets.ts +1 -1
- package/src/features/install-referrer/installReferrer.ts +3 -3
- package/src/features/journey/calibrationContext.ts +0 -9
- package/src/features/journey/journeyManager.ts +3 -1
- package/src/features/navigation/AutoScreenDetector.ts +4 -4
- package/src/features/ota/OtaOrchestrator.ts +27 -18
- package/src/features/ota/geoCountry.ts +2 -2
- package/src/features/ota/retry.ts +2 -2
- package/src/features/replay/core/logger/logger.ts +0 -4
- package/src/features/replay/integrations/network/networkAdapter.ts +1 -56
- package/src/features/replay/integrations/react-navigation/navigationIntegration.ts +1 -1
- package/src/features/replay/integrations/touch/ReplayRoot.tsx +1 -1
- package/src/features/replay/pipeline/batching/batchManager.ts +1 -1
- package/src/features/replay/pipeline/retry/retryPolicy.ts +1 -1
- package/src/features/replay/public/api.ts +7 -7
- package/src/features/replay/replay/session/sessionOrchestrator.ts +9 -9
- package/src/features/session/BackendSessionAdapter.ts +41 -41
- package/src/features/session/DesktopSessionTransport.ts +4 -2
- package/src/features/session/JourneyEventPipeline.ts +1 -1
- package/src/features/session/ReplayCaptureManager.ts +14 -14
- package/src/features/session/SessionManager.ts +9 -9
- package/src/features/session/SyncDecisionEngine.ts +1 -1
- package/src/features/skan/skanBridge.ts +6 -14
- package/src/features/skan/skanConversionManager.ts +5 -5
- package/src/index.ts +1 -1
- package/src/integrations/fetch/fetchInterceptor.ts +1 -1
- package/src/integrations/xhr/xhrInterceptor.ts +1 -1
- package/src/metro/composeSourceMap.ts +104 -0
- package/src/metro/featureModules.ts +143 -0
- package/src/metro/index.ts +173 -1
- package/src/metro/serializerCompose.ts +157 -0
- package/src/pipeline/dispatcher/dispatcher.ts +1 -1
- package/src/pipeline/queue/flushQueue.ts +2 -2
- package/src/pipeline/queue/persistentQueue.ts +6 -35
- package/src/pipeline/scheduler/flushScheduler.ts +1 -1
- package/src/public/ScaleBunFacade.ts +60 -15
- package/src/public/types.ts +35 -8
- package/src/push/PushManager.ts +3 -3
- package/src/push/adapters/NativeBridgeAdapter.ts +1 -1
- package/src/push/native/nativeNotifications.ts +7 -16
- package/src/storage/StorageBackend.ts +1 -1
|
@@ -114,7 +114,7 @@ export class SDKBootstrapper {
|
|
|
114
114
|
// These are flushed immediately so crash-time events are not lost.
|
|
115
115
|
const leftovers = persistentQueue.drainLeftovers();
|
|
116
116
|
if (leftovers.length > 0) {
|
|
117
|
-
logger.info(`[Bootstrap] ${leftovers.length} leftover envelopes from previous run — will flush`);
|
|
117
|
+
__DEV__ && logger.info(`[Bootstrap] ${leftovers.length} leftover envelopes from previous run — will flush`);
|
|
118
118
|
// Re-add to queue so the normal flush cycle picks them up
|
|
119
119
|
for (const envelope of leftovers) {
|
|
120
120
|
persistentQueue.add(envelope);
|
|
@@ -145,9 +145,9 @@ export class SDKBootstrapper {
|
|
|
145
145
|
// ── Backend handshake ──────────────────────────────────
|
|
146
146
|
if (this.config.clientKey) {
|
|
147
147
|
// SaaS mode: clientKey is resolved by SdkKeyGuard on each request — no token handshake needed
|
|
148
|
-
logger.info('[Bootstrap] SaaS mode: clientKey auth active, skipping legacy handshake');
|
|
148
|
+
__DEV__ && logger.info('[Bootstrap] SaaS mode: clientKey auth active, skipping legacy handshake');
|
|
149
149
|
} else {
|
|
150
|
-
logger.debug('Starting handshake...');
|
|
150
|
+
__DEV__ && logger.debug('Starting handshake...');
|
|
151
151
|
const response = await httpClient.post(ENDPOINTS.SESSIONS, {
|
|
152
152
|
projectId: this.config.projectId,
|
|
153
153
|
publishableKey: this.config.publishableKey,
|
|
@@ -340,7 +340,7 @@ export class SDKBootstrapper {
|
|
|
340
340
|
// ── Session Replay Initialization (Core) ───────────────
|
|
341
341
|
if (features.replay !== false) {
|
|
342
342
|
try {
|
|
343
|
-
logger.debug('[Bootstrap] Initializing unified SessionManager');
|
|
343
|
+
__DEV__ && logger.debug('[Bootstrap] Initializing unified SessionManager');
|
|
344
344
|
const sessionManager = SessionManager.getInstance(
|
|
345
345
|
null, // No desktop transport initially
|
|
346
346
|
nativeCapture,
|
|
@@ -395,15 +395,18 @@ export class SDKBootstrapper {
|
|
|
395
395
|
const analyticsStarted = backendAdapter
|
|
396
396
|
.startAnalyticsSession(this._buildAnalyticsSession());
|
|
397
397
|
|
|
398
|
-
// Cold-launch frame recording. The AppState listener only
|
|
399
|
-
//
|
|
400
|
-
//
|
|
401
|
-
//
|
|
402
|
-
//
|
|
403
|
-
//
|
|
404
|
-
//
|
|
405
|
-
//
|
|
406
|
-
|
|
398
|
+
// Cold-launch frame recording. The AppState listener only starts a
|
|
399
|
+
// recording session on a foreground TRANSITION, which never fires on the
|
|
400
|
+
// initial launch — so without this the first session uploads events but zero
|
|
401
|
+
// frames ("No screen recordings"). Auto-start recording by DEFAULT in SaaS mode
|
|
402
|
+
// so replays appear out of the box; hosts opt out with `replay: { record: false }`
|
|
403
|
+
// for events-only sessions (they can still record on demand via startSession()).
|
|
404
|
+
// Deliberately NOT gated by finalizeOnBackground (that flag only governs
|
|
405
|
+
// per-foreground session boundaries, not whether replay records at all).
|
|
406
|
+
// Started once the analytics session id exists so startSession adopts it
|
|
407
|
+
// (one-row merge) instead of minting an orphan row.
|
|
408
|
+
const shouldAutoRecord = this.config.replay?.record !== false;
|
|
409
|
+
if (shouldAutoRecord) {
|
|
407
410
|
analyticsStarted
|
|
408
411
|
.then(() => {
|
|
409
412
|
if (!sessionManager.isActive) {
|
|
@@ -421,7 +424,7 @@ export class SDKBootstrapper {
|
|
|
421
424
|
// Desktop transport is attached lazily by sessionWiring.ts when
|
|
422
425
|
// enableDebug() is called (development only — production skips this).
|
|
423
426
|
const isSaaS = !!this.config.clientKey;
|
|
424
|
-
logger.info(
|
|
427
|
+
__DEV__ && logger.info(
|
|
425
428
|
`[ScaleBun Session Wiring] mode=${isSaaS ? 'saas' : 'legacy'} ` +
|
|
426
429
|
`backend=${!!this.config.apiBaseUrl} desktop=pending-debug-connect`
|
|
427
430
|
);
|
|
@@ -481,10 +484,10 @@ export class SDKBootstrapper {
|
|
|
481
484
|
}
|
|
482
485
|
} catch { /* no-throw */ }
|
|
483
486
|
|
|
484
|
-
logger.debug(`[AutoScreen] Screen → '${screenName}' (source: ${source})`);
|
|
487
|
+
__DEV__ && logger.debug(`[AutoScreen] Screen → '${screenName}' (source: ${source})`);
|
|
485
488
|
});
|
|
486
489
|
detector.start();
|
|
487
|
-
logger.info('[Bootstrap] Auto screen detection started');
|
|
490
|
+
__DEV__ && logger.info('[Bootstrap] Auto screen detection started');
|
|
488
491
|
|
|
489
492
|
/**
|
|
490
493
|
* Screen detection that never resolves anything must SAY so.
|
|
@@ -520,7 +523,7 @@ export class SDKBootstrapper {
|
|
|
520
523
|
deviceId: getDeviceId(),
|
|
521
524
|
});
|
|
522
525
|
|
|
523
|
-
logger.info('SDK initialized and session established');
|
|
526
|
+
__DEV__ && logger.info('SDK initialized and session established');
|
|
524
527
|
|
|
525
528
|
return {
|
|
526
529
|
config: this.config,
|
package/src/compat/codepush.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { otaOrchestrator } from '../features/ota/OtaOrchestrator';
|
|
2
|
+
import { logger } from '../core/logger/internalLogger';
|
|
2
3
|
|
|
3
4
|
export enum CodePushInstallMode {
|
|
4
5
|
IMMEDIATE = 0,
|
|
@@ -38,12 +39,57 @@ export interface CodePushPackage {
|
|
|
38
39
|
}
|
|
39
40
|
|
|
40
41
|
/**
|
|
41
|
-
* Microsoft CodePush
|
|
42
|
+
* Microsoft CodePush compatibility shim.
|
|
42
43
|
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
44
|
+
* Maps the CodePush surface (`sync`, `checkForUpdate`, the HOC) onto the
|
|
45
|
+
* ScaleBun orchestrator so a migrating app keeps compiling while its call sites
|
|
46
|
+
* are ported.
|
|
47
|
+
*
|
|
48
|
+
* CONFIGURE IT FIRST. This shim used to carry hardcoded defaults —
|
|
49
|
+
* `http://localhost:3001/api/v1` with a dev client key — so a migrated
|
|
50
|
+
* production app silently checked localhost forever and reported UP_TO_DATE on
|
|
51
|
+
* every sync. There is no correct default for someone else's backend, so there
|
|
52
|
+
* is now none: call `configureCodePushShim()` (or `ScaleBun.init({ ota })`,
|
|
53
|
+
* which the facade wires for you) before the first sync, and an unconfigured
|
|
54
|
+
* shim says so loudly instead of pretending to be up to date.
|
|
55
|
+
*
|
|
56
|
+
* import codePush, { configureCodePushShim } from '@scalebun/react-native/compat/codepush';
|
|
57
|
+
* configureCodePushShim({ apiUrl, clientKey, appVersion, installationId });
|
|
58
|
+
*/
|
|
59
|
+
|
|
60
|
+
export interface CodePushShimConfig {
|
|
61
|
+
/** Backend base URL, e.g. https://api.yourbackend.com/api/v1 */
|
|
62
|
+
apiUrl: string;
|
|
63
|
+
/** SDK client key for this app/environment. */
|
|
64
|
+
clientKey: string;
|
|
65
|
+
/** Native app version this binary reports (e.g. '1.4.0'). */
|
|
66
|
+
appVersion: string;
|
|
67
|
+
/** Stable per-install id. Defaults to the SDK's canonical installation id. */
|
|
68
|
+
installationId?: string;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
let shimConfig: CodePushShimConfig | null = null;
|
|
72
|
+
|
|
73
|
+
/** Point the shim at a real backend. Required before sync/checkForUpdate. */
|
|
74
|
+
export function configureCodePushShim(config: CodePushShimConfig): void {
|
|
75
|
+
shimConfig = config;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Resolve the sync params, or null when unconfigured. Returning null (rather
|
|
80
|
+
* than substituting a localhost default) is what turns a silent no-update into
|
|
81
|
+
* a visible, fixable error.
|
|
46
82
|
*/
|
|
83
|
+
function shimParams(): CodePushShimConfig | null {
|
|
84
|
+
if (!shimConfig) {
|
|
85
|
+
logger.warn(
|
|
86
|
+
'[ScaleBun] CodePush shim is not configured — no update check was performed. ' +
|
|
87
|
+
'Call configureCodePushShim({ apiUrl, clientKey, appVersion }) during startup.',
|
|
88
|
+
);
|
|
89
|
+
return null;
|
|
90
|
+
}
|
|
91
|
+
return shimConfig;
|
|
92
|
+
}
|
|
47
93
|
const codePushShim = function <P>(rootComponent: React.ComponentType<P>) {
|
|
48
94
|
return rootComponent;
|
|
49
95
|
};
|
|
@@ -53,14 +99,21 @@ codePushShim.sync = async (
|
|
|
53
99
|
syncStatusCallback?: (status: CodePushSyncStatus) => void,
|
|
54
100
|
downloadProgressCallback?: (progress: { receivedBytes: number; totalBytes: number }) => void,
|
|
55
101
|
): Promise<CodePushSyncStatus> => {
|
|
102
|
+
const params = shimParams();
|
|
103
|
+
if (!params) {
|
|
104
|
+
// Unconfigured is an ERROR, not "up to date": reporting UP_TO_DATE here is
|
|
105
|
+
// exactly how a broken migration stays invisible for months.
|
|
106
|
+
syncStatusCallback?.(CodePushSyncStatus.UNKNOWN_ERROR);
|
|
107
|
+
return CodePushSyncStatus.UNKNOWN_ERROR;
|
|
108
|
+
}
|
|
56
109
|
try {
|
|
57
110
|
syncStatusCallback?.(CodePushSyncStatus.CHECKING_FOR_UPDATE);
|
|
58
111
|
const result = await otaOrchestrator.sync({
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
installationId:
|
|
63
|
-
});
|
|
112
|
+
...params,
|
|
113
|
+
// Omitted → the orchestrator falls back to the SDK's canonical
|
|
114
|
+
// installation id, which is the right identity anyway.
|
|
115
|
+
...(params.installationId ? { installationId: params.installationId } : {}),
|
|
116
|
+
} as any);
|
|
64
117
|
|
|
65
118
|
if (result.status === 'UP_TO_DATE') {
|
|
66
119
|
syncStatusCallback?.(CodePushSyncStatus.UP_TO_DATE);
|
|
@@ -81,16 +134,16 @@ codePushShim.sync = async (
|
|
|
81
134
|
};
|
|
82
135
|
|
|
83
136
|
codePushShim.checkForUpdate = async (): Promise<CodePushPackage | null> => {
|
|
137
|
+
const params = shimParams();
|
|
138
|
+
if (!params) return null;
|
|
84
139
|
const check = await otaOrchestrator.checkForUpdate({
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
installationId: 'codepush_shim',
|
|
89
|
-
});
|
|
140
|
+
...params,
|
|
141
|
+
...(params.installationId ? { installationId: params.installationId } : {}),
|
|
142
|
+
} as any);
|
|
90
143
|
if (check.action === 'NONE' || !check.bundle) return null;
|
|
91
144
|
|
|
92
145
|
return {
|
|
93
|
-
appVersion:
|
|
146
|
+
appVersion: params.appVersion,
|
|
94
147
|
deploymentKey: 'scalebun_ota',
|
|
95
148
|
description: check.bundle.releaseNote ?? '',
|
|
96
149
|
failedInstall: false,
|
|
@@ -111,8 +164,26 @@ codePushShim.allowRestart = () => {
|
|
|
111
164
|
// Scalebun handles restart safety automatically via boot guard
|
|
112
165
|
};
|
|
113
166
|
|
|
167
|
+
/**
|
|
168
|
+
* Metadata for the bundle currently RUNNING. CodePush apps use this to show a
|
|
169
|
+
* version or decide whether a pending update landed; returning a flat null
|
|
170
|
+
* (as this did) makes every such check read as "no OTA bundle installed".
|
|
171
|
+
*/
|
|
114
172
|
codePushShim.getUpdateMetadata = async (): Promise<CodePushPackage | null> => {
|
|
115
|
-
|
|
173
|
+
const current = otaOrchestrator.getCurrentBundle();
|
|
174
|
+
if (!current) return null;
|
|
175
|
+
return {
|
|
176
|
+
appVersion: shimConfig?.appVersion ?? '',
|
|
177
|
+
deploymentKey: 'scalebun_ota',
|
|
178
|
+
description: current.releaseNote ?? '',
|
|
179
|
+
failedInstall: false,
|
|
180
|
+
isFirstRun: false,
|
|
181
|
+
isMandatory: current.isMandatory ?? false,
|
|
182
|
+
isPending: false,
|
|
183
|
+
label: `v${current.version}`,
|
|
184
|
+
packageHash: current.sha256,
|
|
185
|
+
packageSize: current.size,
|
|
186
|
+
};
|
|
116
187
|
};
|
|
117
188
|
|
|
118
189
|
export default codePushShim;
|