From e1c7c44c24f755901749f1f9a8882f4dce6173ca Mon Sep 17 00:00:00 2001 From: Vojtech Novak Date: Wed, 28 Oct 2026 09:22:43 +0100 Subject: [PATCH] docs: spm --- docs/install.mdx | 6 ++---- docs/setting-up/expo.md | 8 ++++---- docs/setting-up/ios.md | 14 +++++++------- 3 files changed, 13 insertions(+), 15 deletions(-) diff --git a/docs/install.mdx b/docs/install.mdx index 07dd9a3..5ae3736 100644 --- a/docs/install.mdx +++ b/docs/install.mdx @@ -163,13 +163,11 @@ There are several guides to follow now: ## Requirements -For latest version of Universal Sign In, `compileSdkVersion` must be {'>='} 35 and `kotlinVersion` must be {'>='} 2.0.21 in your Android project. If you use Expo SDK 53 or newer, these requirements are already met. Use [`expo-build-properties`](https://docs.expo.dev/versions/latest/sdk/build-properties/#example-appjson-with-config-plugin) to specify these values on Expo SDK {'<='} 52. - The latest version of the Universal Sign In package supports (use older versions of the package if you run older React Native / Expo): | | supported range | | ------------ | --------------- | -| expo | 52.0.40 - 57 | -| react-native | 0.76.0 - 0.87 | +| expo | 54+ | +| react-native | 0.81.0+ | > We recommend [Expo](https://expo.dev) and [EAS](https://expo.dev/eas) for building and deploying your React Native app. Expo offers the best developer experience and is well-supported by this library. diff --git a/docs/setting-up/expo.md b/docs/setting-up/expo.md index befdddb..bd8e341 100644 --- a/docs/setting-up/expo.md +++ b/docs/setting-up/expo.md @@ -62,9 +62,9 @@ Place them into your project and specify the paths to the files: ### Swift Package Manager (beta) -Universal Sign In (premium) supports using Swift Package Manager (SPM) for iOS SDK dependencies through CocoaPods. CocoaPods remains the default; SPM is selected automatically when RNFirebase 26.x is autolinked on iOS and Firebase SPM is enabled. RNFirebase 27+ or failed detection requires an explicit override. +Universal Sign In uses CocoaPods by default. It automatically selects SPM for iOS SDK dependencies when RNFirebase 26+ is autolinked on iOS with Firebase SPM enabled. -To choose SPM explicitly, add `iosDependencyManager` to your existing Google Sign-In config plugin options and enable dynamic frameworks with `expo-build-properties`: +SPM requires dynamic frameworks. To select it explicitly: ```json title="app.json | js" { @@ -90,9 +90,9 @@ To choose SPM explicitly, add `iosDependencyManager` to your existing Google Sig } ``` -Install `expo-build-properties` with `npx expo install expo-build-properties` if it is not already installed, then rerun prebuild. For Firebase projects, keep the `googleServicesFile` configuration above; `iosUrlScheme` is only required for projects without Firebase. +`iosDependencyManager` accepts `"auto"` (default), `"cocoapods"`, or `"spm"`. -The `iosDependencyManager` option accepts `"auto"` (default), `"cocoapods"`, or `"spm"`. If you use Firebase, keep both SDKs on the same dependency manager. To switch back to CocoaPods, set `iosDependencyManager` to `"cocoapods"` and set `ios.disableSPM` to `true` in the `@react-native-firebase/app` config plugin options. A `$RNGoogleSigninDependencyManager` assignment in `ios/Podfile` takes precedence over the Expo setting. +Firebase and Google Sign-In must use the same dependency manager. RNFirebase 27+ requires SPM. With RNFirebase 26, set `iosDependencyManager: "cocoapods"` for Google Sign-In and `ios.disableSPM: true` for `@react-native-firebase/app` to use CocoaPods. Full Expo SwiftPM currently requires upstream packaging fixes. See the [iOS guide](./ios#swift-package-manager-beta) for the full SwiftPM preview for bare React Native apps. diff --git a/docs/setting-up/ios.md b/docs/setting-up/ios.md index 259cac8..ed6e1ed 100644 --- a/docs/setting-up/ios.md +++ b/docs/setting-up/ios.md @@ -32,27 +32,27 @@ Do not add version constraints to these declarations. CocoaPods will select vers #### Swift Package Manager (beta) -Universal Sign In (premium) supports Swift Package Manager (SPM) on iOS in beta. Install the npm package as usual. +Universal Sign In uses CocoaPods by default. It automatically selects SPM for iOS SDK dependencies when RNFirebase 26+ is autolinked on iOS with Firebase SPM enabled. -**SPM dependencies through CocoaPods:** CocoaPods remains the default. When RNFirebase 26.x is autolinked on iOS and Firebase SPM is enabled, the package automatically uses SPM for its SDK dependencies. RNFirebase 27+ or failed detection requires an explicit override. - -To choose SPM explicitly, add the following before the target blocks in your `ios/Podfile`, then run `pod install`: +To select SPM explicitly, add this before your Podfile's target blocks: ```ruby title="ios/Podfile" $RNGoogleSigninDependencyManager = 'spm' use_frameworks! :linkage => :dynamic ``` -This integration requires React Native 0.75+ and dynamic frameworks. Remove any forced static linkage for `RNGoogleSignin` or `ReactCodegen`. If you use Firebase, keep both SDKs on the same dependency manager. To switch back to CocoaPods, set `$RNGoogleSigninDependencyManager = 'cocoapods'` and also set `$RNFirebaseDisableSPM = true` if you use RNFirebase. +SPM requires dynamic frameworks. + +Firebase and Google Sign-In must use the same dependency manager. RNFirebase 27+ requires SPM. With RNFirebase 26, switching to CocoaPods requires `$RNGoogleSigninDependencyManager = 'cocoapods'` and `$RNFirebaseDisableSPM = true`. -**Full SwiftPM preview:** For bare React Native apps using the experimental SwiftPM workflow (tested with React Native 0.87), run: +**Full SwiftPM preview:** React Native's experimental CocoaPods-free workflow is tested with RN 0.88. All native dependencies must support SwiftPM. ```sh cd ios npx react-native spm --deintegrate ``` -Build the app's `.xcodeproj`. On fresh checkouts or CI, run `npx react-native spm` from the `ios/` directory. Other native dependencies must also support SwiftPM. Continue with the URL scheme and AppDelegate configuration below. +Build the app's `.xcodeproj`. On fresh checkouts or CI, run `npx react-native spm` from `ios/` first. ### Google project configuration