From d4f785c377b5b461de69d295ab9ee54fefb46ef0 Mon Sep 17 00:00:00 2001 From: Sergio Barrio Date: Thu, 18 Jun 2026 11:41:01 +0200 Subject: [PATCH 1/2] Cleanup of unused imports and parameter documentation --- packages/core/README.md | 6 +++--- .../kotlin/com/datadog/reactnative/DdRumImplementation.kt | 1 + .../kotlin/com/datadog/reactnative/DdSdkConfiguration.kt | 1 - .../com/datadog/reactnative/DdSdkReactNativePackage.kt | 1 - packages/core/ios/Sources/DdLogsImplementation.swift | 2 +- packages/core/ios/Sources/DdSdkConfiguration.swift | 1 - .../reactnative/webview/DdSdkReactNativeWebViewPackage.kt | 2 -- .../ios/Sources/RCTDatadogWebViewManager.mm | 1 - 8 files changed, 5 insertions(+), 10 deletions(-) diff --git a/packages/core/README.md b/packages/core/README.md index 1b864b5c2..0fef6299d 100644 --- a/packages/core/README.md +++ b/packages/core/README.md @@ -51,12 +51,12 @@ const datadogConfiguration = new DatadogProviderConfiguration( trackErrors: true, // track errors nativeCrashReportEnabled: true, // Optional: enable or disable native crash reports sessionSampleRate: 80, // Optional: sample RUM sessions (here, 80% of session will be sent to Datadog. Default = 100%) - resourceTracingSamplingRate: 80, // Optional: sample tracing integrations for network calls between your app and your backend (here, 80% of calls to your instrumented backend will be linked from the RUM view to the APM view. Default = 20%) + resourceTraceSampleRate: 80, // Optional: sample tracing integrations for network calls between your app and your backend (here, 80% of calls to your instrumented backend will be linked from the RUM view to the APM view. Default = 20%) // You need to specify the hosts of your backends to enable tracing with these backends - firstPartyHosts: ['example.com'], // matches 'example.com' and subdomains like 'api.example.com' + firstPartyHosts: ['example.com'] // matches 'example.com' and subdomains like 'api.example.com' }, logsConfiguration: { - logEventMapper: (logEvent) => { + logEventMapper: logEvent => { logEvent.message = `[CUSTOM] ${logEvent.message}`; return logEvent; } diff --git a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdRumImplementation.kt b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdRumImplementation.kt index 692f5a840..41f525761 100644 --- a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdRumImplementation.kt +++ b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdRumImplementation.kt @@ -218,6 +218,7 @@ class DdRumImplementation(private val datadog: DatadogWrapper = DatadogSDKWrappe * @param stacktrace The error stacktrace. * @param context The additional context to send. * @param timestampMs The timestamp when the error occurred (in milliseconds). If not provided, current timestamp will be used. + * @param fingerprint A custom fingerprint to group this error with similar ones. */ @Suppress("LongParameterList") fun addError( diff --git a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfiguration.kt b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfiguration.kt index 4e48ad594..50a3ae377 100644 --- a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfiguration.kt +++ b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfiguration.kt @@ -6,7 +6,6 @@ package com.datadog.reactnative -import com.datadog.android.core.configuration.BatchProcessingLevel import com.datadog.android.trace.TracingHeaderType import java.net.Proxy diff --git a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkReactNativePackage.kt b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkReactNativePackage.kt index 98ffa83db..522e81607 100644 --- a/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkReactNativePackage.kt +++ b/packages/core/android/src/main/kotlin/com/datadog/reactnative/DdSdkReactNativePackage.kt @@ -7,7 +7,6 @@ package com.datadog.reactnative import com.facebook.react.TurboReactPackage -import com.facebook.react.bridge.LifecycleEventListener import com.facebook.react.bridge.NativeModule import com.facebook.react.bridge.ReactApplicationContext import com.facebook.react.module.model.ReactModuleInfo diff --git a/packages/core/ios/Sources/DdLogsImplementation.swift b/packages/core/ios/Sources/DdLogsImplementation.swift index 86620b869..f9d87fced 100644 --- a/packages/core/ios/Sources/DdLogsImplementation.swift +++ b/packages/core/ios/Sources/DdLogsImplementation.swift @@ -95,7 +95,7 @@ public class DdLogsImplementation: NSObject { internal extension DatadogLogs.Logger.Configuration { /// Creates a Logger configuration from briged configuration dictionary. /// - /// - Parameter dictionnary: The configuration from the bridge. + /// - Parameter sdkConfiguration: The configuration from the bridge. init(_ sdkConfiguration: DdSdkConfiguration) { self.init( networkInfoEnabled: true, diff --git a/packages/core/ios/Sources/DdSdkConfiguration.swift b/packages/core/ios/Sources/DdSdkConfiguration.swift index 829aafba3..fd8e8f3e1 100644 --- a/packages/core/ios/Sources/DdSdkConfiguration.swift +++ b/packages/core/ios/Sources/DdSdkConfiguration.swift @@ -190,7 +190,6 @@ public class LogsConfiguration: NSObject { /// A configuration object for Datadog Tracing (APM) features. /// /// - Parameters: -/// - resourceTracingSamplingRate: Percentage (0–100) of network resource traces to sample. /// - customEndpoint: A custom Trace intake endpoint to override the default Datadog intake. public class TraceConfiguration: NSObject { public var customEndpoint: String? = nil diff --git a/packages/react-native-webview/android/src/newarch/com/datadog/reactnative/webview/DdSdkReactNativeWebViewPackage.kt b/packages/react-native-webview/android/src/newarch/com/datadog/reactnative/webview/DdSdkReactNativeWebViewPackage.kt index be3b22ee2..f7b960d01 100644 --- a/packages/react-native-webview/android/src/newarch/com/datadog/reactnative/webview/DdSdkReactNativeWebViewPackage.kt +++ b/packages/react-native-webview/android/src/newarch/com/datadog/reactnative/webview/DdSdkReactNativeWebViewPackage.kt @@ -11,8 +11,6 @@ import com.facebook.react.bridge.ReactApplicationContext import com.facebook.react.module.model.ReactModuleInfo import com.facebook.react.module.model.ReactModuleInfoProvider import com.facebook.react.uimanager.ViewManager -import com.reactnativecommunity.webview.RNCWebViewModule -import com.reactnativecommunity.webview.RNCWebViewModuleImpl class DdSdkReactNativeWebViewPackage : TurboReactPackage() { override fun createViewManagers( diff --git a/packages/react-native-webview/ios/Sources/RCTDatadogWebViewManager.mm b/packages/react-native-webview/ios/Sources/RCTDatadogWebViewManager.mm index 85a39e061..e811bd544 100644 --- a/packages/react-native-webview/ios/Sources/RCTDatadogWebViewManager.mm +++ b/packages/react-native-webview/ios/Sources/RCTDatadogWebViewManager.mm @@ -5,7 +5,6 @@ */ #import -#import #import "RCTDatadogWebViewManager.h" #import "RCTDatadogWebView.h" From 958700310280e68d7a5c9999e65454820f2cb39f Mon Sep 17 00:00:00 2001 From: Sergio Barrio Date: Thu, 18 Jun 2026 11:50:01 +0200 Subject: [PATCH 2/2] Fix typos --- packages/core/README.md | 2 +- packages/core/ios/Sources/DdLogsImplementation.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/core/README.md b/packages/core/README.md index 0fef6299d..38582ceb2 100644 --- a/packages/core/README.md +++ b/packages/core/README.md @@ -53,7 +53,7 @@ const datadogConfiguration = new DatadogProviderConfiguration( sessionSampleRate: 80, // Optional: sample RUM sessions (here, 80% of session will be sent to Datadog. Default = 100%) resourceTraceSampleRate: 80, // Optional: sample tracing integrations for network calls between your app and your backend (here, 80% of calls to your instrumented backend will be linked from the RUM view to the APM view. Default = 20%) // You need to specify the hosts of your backends to enable tracing with these backends - firstPartyHosts: ['example.com'] // matches 'example.com' and subdomains like 'api.example.com' + firstPartyHosts: ['example.com'], // matches 'example.com' and subdomains like 'api.example.com' }, logsConfiguration: { logEventMapper: logEvent => { diff --git a/packages/core/ios/Sources/DdLogsImplementation.swift b/packages/core/ios/Sources/DdLogsImplementation.swift index f9d87fced..a4a8ba04a 100644 --- a/packages/core/ios/Sources/DdLogsImplementation.swift +++ b/packages/core/ios/Sources/DdLogsImplementation.swift @@ -93,7 +93,7 @@ public class DdLogsImplementation: NSObject { } internal extension DatadogLogs.Logger.Configuration { - /// Creates a Logger configuration from briged configuration dictionary. + /// Creates a Logger configuration from bridged configuration dictionary. /// /// - Parameter sdkConfiguration: The configuration from the bridge. init(_ sdkConfiguration: DdSdkConfiguration) {