Flutter's Major Milestone: Material and Cupertino Libraries Decoupled from Framework

From Moocchen, the free encyclopedia of technology

Introduction: A New Chapter for Flutter's Design Libraries

Flutter has reached a significant turning point in its evolution. The foundational Material and Cupertino libraries, long integral to the framework's core, are now frozen and set to transition into standalone packages. This move, effective from April 7th, represents the first major milestone in a carefully orchestrated plan to decouple these design systems from the flutter/flutter repository.

Flutter's Major Milestone: Material and Cupertino Libraries Decoupled from Framework

The ultimate goal is to re-release these libraries as the material_ui and cupertino_ui packages on pub.dev. This shift promises greater flexibility and faster iteration for both the Flutter team and the community. Let’s break down what this means for you and how the migration will unfold.

Impact on Regular Flutter Developers

If You Build Apps or Plugins (But Don’t Contribute to the Libraries Themselves)

For the vast majority of Flutter developers—those who use the Material and Cupertino libraries but don’t actively contribute to their code—the immediate effects are minimal. You can safely continue developing without any changes to your workflow for now. However, a future migration will be required after the 3.44 stable release.

  • Current behavior: No action needed. Your apps will continue to work as before.
  • After 3.44 stable: The new material_ui and cupertino_ui packages will be published. Developers will eventually need to migrate to these packages as the old in-framework code becomes deprecated and later removed.
  • Deprecation timeline: Deprecation warnings will appear in the stable release following 3.44, with removal scheduled for a subsequent release. Detailed migration instructions will be provided when the time comes.

What About Active Contributors?

If you have open pull requests (PRs) or plan to submit changes to Material or Cupertino, here’s what you should know.

Handling Open PRs

Development on these libraries is not halting; it’s simply shifting. All open PRs that touch Material or Cupertino will remain open in flutter/flutter. Reviewers will continue providing feedback as usual. Once the new packages are released, the team will offer guidance on porting these PRs to the flutter/packages repository. Your changes will eventually ship as part of a new version of material_ui or cupertino_ui.

Issues and Bug Reports

Existing and new issues related to Material and Cupertino will stay in the flutter/flutter issue tracker. This unified approach matches the workflow used for other packages in the flutter/packages repository, ensuring continuity and clarity.

Why Freeze the Code Now?

The decision to freeze the Material and Cupertino libraries ahead of the package release is driven by a critical need: ensuring a seamless migration experience. When version 1.0.0 of material_ui and cupertino_ui lands, developers migrating from any Flutter release channel must face minimal risk of breaking changes.

To achieve this, the team is freezing the code one stable release cycle before the packages go live. This frozen version is then copied directly into the new packages. As a result, the code in flutter/flutter and the upcoming packages will be identical, eliminating discrepancies.

For developers, the first step is straightforward: upgrade your Flutter SDK to version 3.44 or later on any channel. This ensures you have the frozen version of Material and Cupertino. Even if you later upgrade the SDK further, that frozen copy remains stable, smoothing the eventual transition to the new packages.

Looking Ahead: What to Expect

The code freeze is just the beginning. Following the 3.44 stable release, the material_ui and cupertino_ui packages will become available. From there, the framework will gradually deprecate the old in-repo libraries. The Flutter team will provide detailed migration guides and tooling to make the switch as painless as possible.

This architectural change aligns with Flutter’s broader strategy of modularization, enabling faster, independent updates to design components. For contributors, it opens new opportunities to shape these packages outside the core framework. For everyday developers, it means a more stable and predictable upgrade path.

Stay tuned for further announcements, and prepare to welcome material_ui and cupertino_ui to your projects.