Skip to content

Conversation

@AesaKamar
Copy link

This PR introduces CocoaPods support for Monarch macOS builds, enabling the use of Flutter plugins that require native dependencies (like Rive, Firebase, etc.).

Summary of changes:

  • Added 'pod install' execution to 'build_platform.dart' during the macOS build process.
  • Updated 'xcodebuild' to use the '.xcworkspace' generated by CocoaPods.
  • Added a generic 'Podfile' template in 'platform/macos/Podfile'.
  • Updated '.gitignore' to exclude CocoaPods artifacts.

@AesaKamar AesaKamar marked this pull request as draft January 19, 2026 22:55
@AesaKamar AesaKamar force-pushed the feature/macos-native-plugin-support branch from 62ee1a9 to 9d106e7 Compare January 19, 2026 22:56
@AesaKamar AesaKamar force-pushed the feature/macos-native-plugin-support branch from 9d106e7 to 36b797d Compare January 19, 2026 22:58
@AesaKamar AesaKamar marked this pull request as ready for review January 19, 2026 22:58
@fertrig
Copy link
Collaborator

fertrig commented Feb 6, 2026

Hi @AesaKamar, good to hear from you!

Are you trying to preview stories that use Rive widgets in Monarch?

This PR hardcodes Rive imports and plugin registrations in WindowManager.swift which would affect all monarch users, even the ones that don't use Rive.

I think you want a way to extend the Monarch host app with your project's native plugins. For example:

A command like monarch build macos that rebuilds the Monarch macOS host app with your project's native plugins:

  1. Reads plugins from your project's pubspec.yaml
  2. Generates a Podfile with those plugins
  3. Runs pod install and xcodebuild
  4. Outputs a custom Monarch macOS app to .monarch/ in the user's project

Users without native plugins continue using the pre-built binaries. Users with native plugins run monarch build macos once (and again when plugins change).

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.

2 participants