@react-native-firebase/crashlytics 26.0.0 → 26.1.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/CHANGELOG.md +6 -0
- package/RNFBCrashlytics.podspec +12 -2
- package/dist/module/version.js +1 -1
- package/dist/typescript/lib/index.d.ts +1 -1
- package/dist/typescript/lib/version.d.ts +1 -1
- package/ios/RNFBCrashlytics/RNFBCrashlyticsInitProvider.h +15 -6
- package/ios/RNFBCrashlytics/RNFBCrashlyticsInitProvider.m +24 -1
- package/ios/RNFBCrashlytics/RNFBCrashlyticsModule.mm +8 -0
- package/ios/RNFBCrashlytics/RNFBCrashlyticsNativeHelper.m +8 -0
- package/ios_config.sh +19 -2
- package/lib/version.ts +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [26.1.0](https://github.com/invertase/react-native-firebase/compare/v26.0.0...v26.1.0) (2026-08-03)
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
- **ios:** add SPM dependency resolution support alongside CocoaPods ([#8933](https://github.com/invertase/react-native-firebase/issues/8933)) ([44a7a9a](https://github.com/invertase/react-native-firebase/commit/44a7a9ae7b404f412e9766c0417f1df8fa971a0b))
|
|
11
|
+
|
|
6
12
|
## [26.0.0](https://github.com/invertase/react-native-firebase/compare/v25.1.0...v26.0.0) (2026-07-29)
|
|
7
13
|
|
|
8
14
|
### ⚠ BREAKING CHANGES
|
package/RNFBCrashlytics.podspec
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
require 'json'
|
|
2
|
+
require_relative '../app/firebase_spm'
|
|
2
3
|
package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
|
|
3
4
|
appPackage = JSON.parse(File.read(File.join('..', 'app', 'package.json')))
|
|
4
5
|
|
|
@@ -50,8 +51,17 @@ Pod::Spec.new do |s|
|
|
|
50
51
|
end
|
|
51
52
|
|
|
52
53
|
# Firebase dependencies
|
|
53
|
-
|
|
54
|
-
|
|
54
|
+
# FirebaseCoreExtension is a transitive dependency of FirebaseCrashlytics in SPM,
|
|
55
|
+
# so it only needs to be declared explicitly for CocoaPods. Note: it cannot be listed
|
|
56
|
+
# as an explicit SPM product here even if we wanted to -- Firebase's Package.swift only
|
|
57
|
+
# exposes it as an internal `.target`, never as a `.library` product, so
|
|
58
|
+
# `spm_dependency(products: ['FirebaseCoreExtension'])` fails with "Missing package
|
|
59
|
+
# product" (verified). See okf-bundle/ios-spm-native-imports.md for the resulting
|
|
60
|
+
# `__has_include` failure and its fix.
|
|
61
|
+
firebase_dependency(s, firebase_sdk_version,
|
|
62
|
+
['FirebaseCrashlytics'],
|
|
63
|
+
['Firebase/Crashlytics', 'FirebaseCoreExtension']
|
|
64
|
+
)
|
|
55
65
|
|
|
56
66
|
if defined?($RNFirebaseAsStaticFramework)
|
|
57
67
|
Pod::UI.puts "#{s.name}: Using overridden static_framework value of '#{$RNFirebaseAsStaticFramework}'"
|
package/dist/module/version.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { FirebaseApp } from '@react-native-firebase/app';
|
|
2
2
|
import './types/internal';
|
|
3
3
|
import type { Crashlytics } from './types/crashlytics';
|
|
4
|
-
export declare const SDK_VERSION = "26.
|
|
4
|
+
export declare const SDK_VERSION = "26.1.0";
|
|
5
5
|
export declare function getCrashlytics(app?: FirebaseApp): Crashlytics;
|
|
6
6
|
export declare function checkForUnsentReports(crashlytics: Crashlytics): Promise<boolean>;
|
|
7
7
|
export declare function deleteUnsentReports(crashlytics: Crashlytics): Promise<void>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const version = "26.
|
|
1
|
+
export declare const version = "26.1.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
|
@@ -15,10 +15,23 @@
|
|
|
15
15
|
*
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
-
#import <FirebaseCoreExtension/FIRLibrary.h>
|
|
19
18
|
#import <Foundation/Foundation.h>
|
|
20
19
|
|
|
21
|
-
|
|
20
|
+
// This header is intentionally Firebase-free. It's imported by
|
|
21
|
+
// RNFBCrashlyticsModule.mm (Objective-C++), which only ever calls the three
|
|
22
|
+
// plain BOOL class methods below. The `<FIRLibrary>` conformance and
|
|
23
|
+
// `+componentsToRegister` (which needs `FIRComponent`/`FIRLibrary` from
|
|
24
|
+
// FirebaseCoreExtension) are declared privately in RNFBCrashlyticsInitProvider.m
|
|
25
|
+
// instead -- they're only invoked by Firebase's own component/DI runtime via
|
|
26
|
+
// reflection, never called directly by RNFB code, so they don't need to be
|
|
27
|
+
// visible here. This avoids `FirebaseCoreExtension/FIRLibrary.h` (whose
|
|
28
|
+
// `__has_include` check is unreliable under this repo's hybrid SPM+CocoaPods
|
|
29
|
+
// setup, since FirebaseCoreExtension is only a transitive SPM dependency and
|
|
30
|
+
// can't be declared as its own SPM product -- see
|
|
31
|
+
// okf-bundle/ios-spm-native-imports.md) ever being parsed from a `.mm` file,
|
|
32
|
+
// which is what previously failed with "use of '@import' when C++ modules are
|
|
33
|
+
// disabled".
|
|
34
|
+
@interface RNFBCrashlyticsInitProvider : NSObject
|
|
22
35
|
|
|
23
36
|
+ (BOOL)isCrashlyticsCollectionEnabled;
|
|
24
37
|
|
|
@@ -26,8 +39,4 @@
|
|
|
26
39
|
|
|
27
40
|
+ (BOOL)isCrashlyticsJavascriptExceptionHandlerChainingEnabled;
|
|
28
41
|
|
|
29
|
-
/// Returns one or more FIRComponents that will be registered in
|
|
30
|
-
/// FIRApp and participate in dependency resolution and injection.
|
|
31
|
-
+ (NSArray<FIRComponent *> *)componentsToRegister;
|
|
32
|
-
|
|
33
42
|
@end
|
|
@@ -16,13 +16,27 @@
|
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
18
|
#import "RNFBCrashlyticsInitProvider.h"
|
|
19
|
+
#if __has_include(<Firebase/Firebase.h>)
|
|
19
20
|
#import <Firebase/Firebase.h>
|
|
21
|
+
#elif __has_include(<FirebaseCore/FirebaseCore.h>)
|
|
22
|
+
#import <FirebaseCore/FirebaseCore.h>
|
|
23
|
+
#else
|
|
24
|
+
@import FirebaseCore;
|
|
25
|
+
#endif
|
|
26
|
+
#if __has_include(<FirebaseCoreExtension/FIRAppInternal.h>)
|
|
20
27
|
#import <FirebaseCoreExtension/FIRAppInternal.h>
|
|
21
28
|
#import <FirebaseCoreExtension/FIRComponent.h>
|
|
22
29
|
#import <FirebaseCoreExtension/FIRComponentContainer.h>
|
|
23
30
|
#import <FirebaseCoreExtension/FIRComponentType.h>
|
|
24
31
|
#import <FirebaseCoreExtension/FIRLibrary.h>
|
|
32
|
+
#else
|
|
33
|
+
@import FirebaseCoreExtension;
|
|
34
|
+
#endif
|
|
35
|
+
#if __has_include(<FirebaseCrashlytics/FIRCrashlytics.h>)
|
|
25
36
|
#import <FirebaseCrashlytics/FIRCrashlytics.h>
|
|
37
|
+
#else
|
|
38
|
+
@import FirebaseCrashlytics;
|
|
39
|
+
#endif
|
|
26
40
|
#import "RNFBJSON.h"
|
|
27
41
|
#import "RNFBMeta.h"
|
|
28
42
|
#import "RNFBPreferences.h"
|
|
@@ -46,8 +60,17 @@ NSString *const KEY_CRASHLYTICS_JAVASCRIPT_EXCEPTION_HANDLER_CHAINING_ENABLED =
|
|
|
46
60
|
@protocol FIRCrashlyticsInstanceProvider <NSObject>
|
|
47
61
|
@end
|
|
48
62
|
|
|
49
|
-
/// Privately conform to the protocol for component registration.
|
|
63
|
+
/// Privately conform to the protocol for component registration. `<FIRLibrary>` and
|
|
64
|
+
/// `+componentsToRegister` live here rather than in RNFBCrashlyticsInitProvider.h because
|
|
65
|
+
/// they're only invoked by Firebase's own component/DI runtime via reflection, never by RNFB
|
|
66
|
+
/// code directly -- keeping them out of the public header keeps it Firebase-free (see header
|
|
67
|
+
/// comment and okf-bundle/ios-spm-native-imports.md).
|
|
50
68
|
@interface RNFBCrashlyticsInitProvider () <RNFBCrashlyticsInitProviderProtocol, FIRLibrary>
|
|
69
|
+
|
|
70
|
+
/// Returns one or more FIRComponents that will be registered in
|
|
71
|
+
/// FIRApp and participate in dependency resolution and injection.
|
|
72
|
+
+ (NSArray<FIRComponent *> *)componentsToRegister;
|
|
73
|
+
|
|
51
74
|
@end
|
|
52
75
|
|
|
53
76
|
@implementation RNFBCrashlyticsInitProvider
|
|
@@ -22,7 +22,15 @@
|
|
|
22
22
|
#import <React/RCTLog.h>
|
|
23
23
|
#import <React/RCTUtils.h>
|
|
24
24
|
|
|
25
|
+
#if __has_include(<Firebase/Firebase.h>)
|
|
25
26
|
#import <Firebase/Firebase.h>
|
|
27
|
+
#elif __has_include(<FirebaseCrashlytics/FirebaseCrashlytics.h>)
|
|
28
|
+
#import <FirebaseCore/FirebaseCore.h>
|
|
29
|
+
#import <FirebaseCrashlytics/FirebaseCrashlytics.h>
|
|
30
|
+
#else
|
|
31
|
+
@import FirebaseCore;
|
|
32
|
+
@import FirebaseCrashlytics;
|
|
33
|
+
#endif
|
|
26
34
|
#import "RNFBApp/RNFBSharedUtils.h"
|
|
27
35
|
#import "RNFBCrashlyticsInitProvider.h"
|
|
28
36
|
#import "RNFBCrashlyticsModule.h"
|
|
@@ -17,7 +17,15 @@
|
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
19
|
#import "RNFBCrashlyticsNativeHelper.h"
|
|
20
|
+
#if __has_include(<Firebase/Firebase.h>)
|
|
20
21
|
#import <Firebase/Firebase.h>
|
|
22
|
+
#elif __has_include(<FirebaseCrashlytics/FirebaseCrashlytics.h>)
|
|
23
|
+
#import <FirebaseCore/FirebaseCore.h>
|
|
24
|
+
#import <FirebaseCrashlytics/FirebaseCrashlytics.h>
|
|
25
|
+
#else
|
|
26
|
+
@import FirebaseCore;
|
|
27
|
+
@import FirebaseCrashlytics;
|
|
28
|
+
#endif
|
|
21
29
|
|
|
22
30
|
@implementation RNFBCrashlyticsNativeHelper
|
|
23
31
|
|
package/ios_config.sh
CHANGED
|
@@ -16,10 +16,27 @@
|
|
|
16
16
|
#
|
|
17
17
|
set -e
|
|
18
18
|
|
|
19
|
-
if [[ ${PODS_ROOT} ]]; then
|
|
19
|
+
if [[ ${PODS_ROOT} && -f "${PODS_ROOT}/FirebaseCrashlytics/run" ]]; then
|
|
20
20
|
echo "info: Exec FirebaseCrashlytics Run from Pods"
|
|
21
21
|
"${PODS_ROOT}/FirebaseCrashlytics/run"
|
|
22
|
-
|
|
22
|
+
elif [[ -f "${PROJECT_DIR}/FirebaseCrashlytics.framework/run" ]]; then
|
|
23
23
|
echo "info: Exec FirebaseCrashlytics Run from framework"
|
|
24
24
|
"${PROJECT_DIR}/FirebaseCrashlytics.framework/run"
|
|
25
|
+
else
|
|
26
|
+
# SPM: upload-symbols is at a known path in the SourcePackages checkout.
|
|
27
|
+
# BUILD_DIR is typically DerivedData/Project-hash/Build/Products — strip from /Build onward
|
|
28
|
+
# to get the DerivedData project root where SourcePackages lives.
|
|
29
|
+
SPM_CRASHLYTICS_DIR="${BUILD_DIR%Build/*}SourcePackages/checkouts/firebase-ios-sdk/Crashlytics"
|
|
30
|
+
SPM_UPLOAD_SYMBOLS="${SPM_CRASHLYTICS_DIR}/upload-symbols"
|
|
31
|
+
if [[ -x "${SPM_UPLOAD_SYMBOLS}" ]]; then
|
|
32
|
+
echo "info: Exec FirebaseCrashlytics upload-symbols from SPM"
|
|
33
|
+
"${SPM_UPLOAD_SYMBOLS}" -gsp "${PROJECT_DIR}/GoogleService-Info.plist" -p ios "${DWARF_DSYM_FOLDER_PATH}/${DWARF_DSYM_FILE_NAME}"
|
|
34
|
+
elif [[ -f "${SPM_UPLOAD_SYMBOLS}" ]]; then
|
|
35
|
+
echo "info: Exec FirebaseCrashlytics upload-symbols from SPM (chmod +x)"
|
|
36
|
+
chmod +x "${SPM_UPLOAD_SYMBOLS}"
|
|
37
|
+
"${SPM_UPLOAD_SYMBOLS}" -gsp "${PROJECT_DIR}/GoogleService-Info.plist" -p ios "${DWARF_DSYM_FOLDER_PATH}/${DWARF_DSYM_FILE_NAME}"
|
|
38
|
+
else
|
|
39
|
+
echo "warning: FirebaseCrashlytics run script not found at CocoaPods, framework, or SPM paths. Skipping dSYM upload."
|
|
40
|
+
echo "warning: Checked: \${PODS_ROOT}/FirebaseCrashlytics/run, \${PROJECT_DIR}/FirebaseCrashlytics.framework/run, ${SPM_UPLOAD_SYMBOLS}"
|
|
41
|
+
fi
|
|
25
42
|
fi
|
package/lib/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Generated by genversion.
|
|
2
|
-
export const version = '26.
|
|
2
|
+
export const version = '26.1.0';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@react-native-firebase/crashlytics",
|
|
3
|
-
"version": "26.
|
|
3
|
+
"version": "26.1.0",
|
|
4
4
|
"author": "Invertase <oss@invertase.io> (http://invertase.io)",
|
|
5
5
|
"description": "React Native Firebase - Firebase Crashlytics is a lightweight, realtime crash reporter that helps you track, prioritize, and fix stability issues that erode your app quality. React Native Firebase provides automatic crash reporting for both native and JavaScript errors, including unhandled promise rejections.",
|
|
6
6
|
"main": "./dist/module/index.js",
|
|
@@ -47,14 +47,14 @@
|
|
|
47
47
|
"crashlytics"
|
|
48
48
|
],
|
|
49
49
|
"peerDependencies": {
|
|
50
|
-
"@react-native-firebase/app": "26.
|
|
50
|
+
"@react-native-firebase/app": "26.1.0",
|
|
51
51
|
"expo": ">=47.0.0"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"stacktrace-js": "^2.0.2"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
|
-
"@react-native-firebase/app": "26.
|
|
57
|
+
"@react-native-firebase/app": "26.1.0",
|
|
58
58
|
"expo": "^55.0.18",
|
|
59
59
|
"react-native-builder-bob": "^0.41.0",
|
|
60
60
|
"typescript": "^6.0.3"
|
|
@@ -102,5 +102,5 @@
|
|
|
102
102
|
]
|
|
103
103
|
]
|
|
104
104
|
},
|
|
105
|
-
"gitHead": "
|
|
105
|
+
"gitHead": "59d053eca14ab8aa80e5ac76887014925c67e52b"
|
|
106
106
|
}
|