Skip to content

docs(app-check): update doc accordingly to new AppDelegate.swift in rn 0.79 #8479

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 28, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 26 additions & 1 deletion docs/app-check/usage/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,32 @@ For instructions on how to generate required keys and register an app for the de

You must call initialize the AppCheck module prior to calling any firebase back-end services for App Check to function.

#### Configure AppCheck with iOS credentials (react-native 0.77+)
#### Configure AppCheck with iOS credentials (react-native 0.79+)

To do that, edit your `ios/ProjectName/AppDelegate.swift` and add the following two lines:

At the top of the file, import the FirebaseCore SDK right after `import UIKit`:
And within your existing `didFinishLaunchingWithOptions` method, add the following to the top of the method:

```diff
import UIKit
+ import RNFBAppCheck // <-- This is the import for AppCheck to work
+ import FirebaseCore // <-- From App/Core integration, no other Firebase items needed
import React
import React_RCTAppDelegate
import ReactAppDependencyProvider

...

func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
) -> Bool {
+ RNFBAppCheckModule.sharedInstance() // <-- new for AppCheck to work
+ FirebaseApp.configure() // <-- From App/Core integration
```

#### Configure AppCheck with iOS credentials (react-native >= 0.77 && < 0.79)

To do that, edit your `ios/ProjectName/AppDelegate.swift` and add the following two lines:

Expand Down
Loading