Image for post
Image for post

Announcing: Flutter Community Plus Plugins📣

The Plus Plugins are a suite of open-source Flutter plugins that take some of the most common existing packages to the next level!

Majid Hajian
Oct 13 · 5 min read

We’re delighted to introduce our initial release of Plus plugins, with extensive support for most platforms. This builds on the foundation set by the Flutter Team's plugins to enable Flutter developers to build their apps for different platforms out of the box.

Plus plugins website

We have created a website to display our progress in supporting different platforms. You may check this website plus.fluttercommunity.dev and see what we are doing.

Image for post
Image for post

List of plus plugins

By developing these plugins, we have three main goals:

1- Supporting Federated plugins

Federated plugins are a way of splitting support for different platforms into separate packages. So, a federated plugin can use one package for iOS, another for Android, another for web, and yet another for a car (as an example of an IoT device). Among other benefits, this approach allows a domain expert to extend an existing plugin to work for the platform they know best.

A federated plugin requires the following packages:

app-facing package: that plugin users depend on to use the plugin. This package specifies the API used by the Flutter app.

Platform package(s): One or more packages that contain the platform-specific implementation code. The app-facing package calls into these packages — they aren’t included in an app unless they contain platform-specific functionality accessible to the end-user.

Platform interface package: that glues the app-facing packing to the platform package(s). This package declares an interface that any platform package must implement to support the app-facing package. Having a single package that defines this interface ensures that all platform packages implement the same functionality uniformly.

2- Supporting and maintaining all platforms

We want to support any platform that Flutter supports as quickly as possible. So, we strive to keep our plus plugins in sync with all different stages of Flutter releases such as ‘master,’ ‘dev’. We want to extend our documentation, examples, and fixing issues from the Flutter plugins repository. We are collaborating with the Flutter Team to make sure we can quickly find out about an issue and resolve it in our plus packages. Having high-quality plugins is our end goal.

3- Updating to plus plugins with minimal effort

We have made a considerable effort to maintain backward compatibility so that the new plug packages are a simple drop-in replacement for the current ones. So with almost no effort, you can get the same functionality as the current ones. With that said, we will be updating the packages and adding new features in the future.

Updating steps

We have created these packages in a way that there will be minimal effort to update with current packages. What you need to do is only to add these packages to your pubspec.yaml file and then replace the old import with a new one. An example of this will be device_info_plus

You may have the current plugin installed

Image for post
Image for post

You need to remove this package and install package_info_plus

Image for post
Image for post

Then you should replace this with plus plugin

from

import ‘package:device_info/device_info.dart’;

to

import ‘package:device_info_plus/device_info_plus.dart’;

That’s it. You do not need anything else. However, you may get more functionality from these packages that you may need to consult with documentation or README file.

Plus Plugins anatomy

We are using a monorepo to maintain all plus plugins and each plugin contains platform interfaces, the app-face package, and platform packages. An example of this is the device_info_plusplugin:

Image for post
Image for post

Let’s dig into platform_interface package first.

Image for post
Image for post

This enables us to declare an interface that can be used to create all other platforms.

Now let’s dive into linux package

Image for post
Image for post

The structure is fairly similar; however, the platform-specific implementation may contain native code too.

This is just the beginning

We have started with the mentioned plugins, but that’s not all. We have many other plugins and plans already that we are hoping to deliver to you.

Your Contributions

The Flutter Community Plus Team hopes that you, our amazing Flutter developers, and awesome followers, can give our plus packages a try and help us find out about potential bugs by opening an issue or perhaps fixing or improving these plugins by sending your top-notch PR. After all, we are developing these plugins for all of us. Let’s make them better together.

Road Map

There are several missing platform implementations that are still work in progress. We are trying our best to deliver a stable version of all plus plugins supporting all platforms that Flutter supports by end of mid-November 2020. Meanwhile, you may see several releases from now.

The next step is to create a nice-looking website and adding proper documentation with more examples and sample codes hopefully in November.

Last but not least, Our process automation from release to pub.dev to generate API documentation and deployment is under development and we aim to finish it up before we release a stable version of each plugin. To read more please follow this issue on the plus_plugins repository.

Summary

We have seen that the Flutter Team is slow or they have different priority time to time in order to resolve issues for these plugins and adding more platform supports as quickly as possible, Therefore, we decided to develop these plugins and hope that we can help the Flutter Team and contribute to Flutter Community extensively.

The plus plugins initial release may have some issues, but there’s so much good stuff in at the moment that I mentioned above. We hope this release helps you replace your exciting current plugins with almost no effort! So, that you can come back to us with your invaluable feedback. Thank you for your support — we are building all of these plugins just for you.

Last, special thanks to our amazing contributors who without them it was not possible to release these packages.

Follow us on Twitter: https://twitter.com/FlutterComm

Flutter Community

Articles and Stories from the Flutter Community

Thanks to Simon Lightfoot and Miguel Beltran

Majid Hajian

Written by

Passionate software developer, Huge fan of Flutter/Dart, PWA, and performance. I’ll help developers to level-up. This makes me happy.

Flutter Community

Articles and Stories from the Flutter Community

Majid Hajian

Written by

Passionate software developer, Huge fan of Flutter/Dart, PWA, and performance. I’ll help developers to level-up. This makes me happy.

Flutter Community

Articles and Stories from the Flutter Community

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store