Skip to content

refactor(core,apple): migrate iOS/macOS plugin implementation to Swift - #18569

Merged
SelaseKay merged 3 commits into
mainfrom
feat/core-pigeon-swift
Aug 18, 2026
Merged

refactor(core,apple): migrate iOS/macOS plugin implementation to Swift#18569
SelaseKay merged 3 commits into
mainfrom
feat/core-pigeon-swift

Conversation

@SelaseKay

@SelaseKay SelaseKay commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Description

Migrates firebase_core on iOS and macOS from the Pigeon Objective-C generator (objcOut) to Swift (swiftOut), matching recent plugin migrations such as Crashlytics.

The HostApi implementation is now Swift (FLTFirebaseCorePlugin), still registered as pluginClass: FLTFirebaseCorePlugin. Shared ObjC helpers (FLTFirebasePlugin / FLTFirebasePluginRegistry) stay ObjC in a separate firebase_core_objc SPM target because SPM cannot mix Swift and ObjC in one target.

FirebaseOptions.authDomain is not a native FirebaseApp field, so custom auth domains are stored on FLTFirebasePlugin (keyed by iOS app name) instead of the Core plugin class. firebase_auth now reads [FLTFirebasePlugin getCustomDomain:] and no longer imports FLTFirebaseCorePlugin.h.

Android is unchanged in this PR (Java HostApi + javaOut remain). A follow-up Kotlin PR will stack on this branch because both migrations edit pigeons/messages.dart.

Dart unit tests for firebase_core and firebase_core_platform_interface passed locally. Native iOS/macOS builds and melos run analyze were not run in this change.

Related Issues

None

Checklist

Before you create this PR confirm that it meets all requirements listed below by checking the relevant checkboxes ([x]).
This will ensure a smooth and quick review process. Updating the pubspec.yaml and changelogs is not required.

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • My PR includes unit or integration tests for all changed/updated/fixed behaviors (See Contributor Guide).
  • All existing and new tests are passing.
  • I updated/added relevant documentation (doc comments with ///).
  • The analyzer (melos run analyze) does not report any problems on my PR.
  • I read and followed the Flutter Style Guide.
  • I signed the CLA.
  • I am willing to follow-up on review comments in a timely manner.

Breaking Change

Does your PR require plugin users to manually update their apps to accommodate your change?

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

Switch firebase_core from Pigeon objcOut to swiftOut and implement the
HostApi in Swift. Custom auth domains now live on FLTFirebasePlugin so
firebase_auth does not depend on the Core plugin class.
@gemini-code-assist

Copy link
Copy Markdown
Contributor
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

…ror conformance

CocoaPods mixed Swift/ObjC builds require firebase_core/firebase_core.h, which
the generated Swift overlay imports. Other Swift plugins inherit FlutterError:
Error from firebase_core, so duplicate conformances are removed.
@SelaseKay
SelaseKay merged commit 3b9a655 into main Aug 18, 2026
110 of 111 checks passed
@SelaseKay
SelaseKay deleted the feat/core-pigeon-swift branch August 18, 2026 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants