refactor(app-check)!: match AppCheck type with firebase-js-sdk#8889
refactor(app-check)!: match AppCheck type with firebase-js-sdk#8889russellwheatley wants to merge 25 commits intomainfrom
Conversation
…AR_DEPRECATION_ARG
…pcheck.ts type so modular only
…s another change needed
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
mikehardy
left a comment
There was a problem hiding this comment.
Code looks good - but the docs (migrating to v24 + AppCheck docs with our custom provider config info example etc) definitely need an update for this one or the support load in the area will stay high vs immediately going to zero
|
Hello 👋, this PR has been opened for more than 14 days with no activity on it. If you think this is a mistake please comment and ping a maintainer to get this merged ASAP! Thanks for contributing! You have 7 days until this gets closed automatically |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #8889 +/- ##
==========================================
- Coverage 74.84% 71.22% -3.62%
==========================================
Files 213 264 +51
Lines 8966 13521 +4555
Branches 2081 3396 +1315
==========================================
+ Hits 6710 9629 +2919
- Misses 2185 3814 +1629
- Partials 71 78 +7 🚀 New features to boost your workflow:
|
Description
Updates to match firebase-js-sdk:
AppChecknow matches firebase-js-sdk (no instance methods); use modular functions likeinitializeAppCheck,getToken,getLimitedUseToken,setTokenAutoRefreshEnabled,onTokenChangedinstead, matching firebase-js-sdk. See commit 423b3e915.onTokenChangedcallback result type changed fromAppCheckListenerResulttoAppCheckTokenResult. See commit 86982934a.FirebaseAppis no longer exported from@react-native-firebase/app-check; importFirebaseAppfrom@react-native-firebase/app. See commit 423b3e915.AppCheckStatics), aligning closer to firebase-js-sdk. See commit f5de6b89b.FirebaseAppCheckTypesis now a type-only export (no runtime export); update any value imports toimport type. See commit 540ee789f.lib/providers.ts(exports updated). See commit 76ab3a848.Related issues
Release Summary
Checklist
AndroidiOSOther(macOS, web)e2etests added or updated inpackages/\*\*/e2ejesttests added or updated inpackages/\*\*/__tests__Test Plan
Think
react-native-firebaseis great? Please consider supporting the project with any of the below:React Native FirebaseandInvertaseon TwitterNote
Medium Risk
Breaking API surface/type changes for App Check modular consumers (instance methods removed, listener callback type changed, exports moved), plus refactors to provider exports and internal typings; risk is mainly ecosystem breakage rather than runtime behavior.
Overview
Aligns
@react-native-firebase/app-checkmodular API with the Firebase JS SDK by making modularAppChecka lightweight handle (no instance methods) and requiring use of modular functions likeinitializeAppCheck,getToken,getLimitedUseToken,setTokenAutoRefreshEnabled, andonTokenChanged.Updates App Check typing/exports:
onTokenChangedmodular callback now yieldsAppCheckTokenResult(notAppCheckListenerResult),FirebaseAppCheckTypesbecomes a type-only export moved intotypes/namespaced, provider classes move tolib/providers.ts, andFirebaseAppis no longer exported from app-check (use@react-native-firebase/app). Documentation and migration guides are updated for v25, a new type-drift compare config is added for app-check, and the AI package’s App Check token hookup is adjusted to match the new type surface.Reviewed by Cursor Bugbot for commit 28b725e. Bugbot is set up for automated code reviews on this repo. Configure here.