Flutter 3 - Whats New For Mobile App Developers?

In Mobile App Development

Flutter 3 - Whats New For Mobile App Developers? - read the full article about Flutter, Mobile App Development and Native and cross-platform solutions from Academind on Qualified.One
Youtube Blogger

Flutter version 3 was released, and version 3 sounds like a big new version that changes everything, or at least a lot, but whether its really a big important new version and change for you, simply depends on what youre using Flutter for.

If you are primarily using it for mobile app development for iOS and Android, as Im doing, then it might not be that next big version that changes everything and introduces a ton of new features.

If you are on the upper hand, exploring Flutter to build cross platform apps, most importantly also desktop applications for macOS, Linux and Windows, then Flutter 3 might be a major step up for you.

Now to find out whats new in Flutter 3, lets simply explore the official announcement blog post, because that is probably the best source to learn which big new features were introduced.

And if you take a look at that blog post, which is all attached to this video by the way, then you will quickly notice that it starts with desktop, Flutter for Desktop.

Its now ready for production on all desktop platforms and especially Linux and macOS have reached stable support now, which means it should now be safe to use Flutter for building desktop applications for Linux and macOS.

It was stable for Windows before version three already, but now its basically stable for all desktop platforms.

And thats why they released this new major version.

Now you can argue about the versioning policy used by Flutter.

Theyre definitely not following semantic versioning in the traditional sense I would argue, but thats up to them.

Here, the major new version was released because now Flutter is stable for all desktop platforms.

Thats the main reason.

And if you scroll through the rest of this announcement blog post, you in the end learn that there are more desktop related changes or features which are now ready for usage.

And if we scroll down further, we then find the first pieces of information for Flutter for Mobile which is that now it supports foldable phones.

So basically, tablets support which they had before, now also for tablets that can turn into phones, you could say, because thats basically what foldables are, you could argue.

So they have better support for this now.

They support iOS variable refresh rate.

So their rendering engine is able to better work with that variable refresh rate, which is of course great.

But if we read through that, we can clearly see that there arent any changes yet that would really have an impact on your code if you are focusing on Flutter for Mobile.

If we continue scrolling, we learn that there also are some updates for Flutter for Web, for example, it now should be able to render images more efficiently.

Though I will say that personally, Im still not 100% sold on using Flutter for Web, because Im yet to be convinced that it really gives me the same performance and usability as a traditional web app built with traditional web technologies does, but that opinion might of course change in the future.

Now, still, nothing major about Flutter for Mobile.

And thats what I meant initially in this video.

If you are primarily using Flutter for mobile app development, up to this point, there isnt any change that would really impact you.

Now, if you continue reading, we also got performance improvements, which is always nice, but which you get for free, basically, no adjustments in code needed here.

And then here at the end, we reach the parts that are most interesting to me, because here theyre talking about Material 3 which is the next iteration of the Material Design Language, and the support for Material 3 in Flutter.

And the important thing here is that now we have more widgets that support Material 3, so Material Design 3.

But its still opt in. Its not the default.

The default still is the old Material 2 design, and we also still dont have all components or all widgets migrated to Material 3.

Indeed, there is a link to a GitHub issue where you can track the Material 3 adoption of Flutter widgets.

And in here, what you learn is whilst a lot of widgets have been migrated already, there also are many widgets which have not been migrated yet.

And that is what matters most to me because thats actually a part Im looking forward to and which I then will probably also use as a trigger once we have all those widgets migrated, and once Material 3 is the default for me to for example, rerecord my Flutter course, if needed which probably will be the case, but right now were not there yet.

Right now, were still using that old Material 2 Design Language or those old Material 2 widgets, and the old Material 2 theming as a default.

And Material 3 which is the new Material version is not fully supported by Flutter yet.

And therefore, if you are primarily into mobile development with Flutter, thats actually a thing Im looking forward to because I like working with Material, and right now I cant use that latest version because we dont have full support for it here in Flutter yet.

And this issue by the way which is all attached to this video, is a great place to stay updated with the support of Material 3 in Flutter.

So, Flutter 3 does not have full support for Material 3 yet.

And if you wanna use it, its opt in and only certain widgets support it.

We have to wait for a future release for Material 3 to be the standard default for Flutter, and for all widgets supporting Material 3.

Now a nice feature we do get with Flutter 3 are theme extensions, which makes theming a bit more convenient and which makes customizing themes a bit more convenient.

And I will explore this feature in my course in the future as well, because Im interested in this as well, but I first have to work with it a bit more.

But the idea basically is that it should get easier to add custom colors and custom color names to a Flutter theme to then use it throughout your entire Flutter app, so that youre not stuck to the default colors, or adding your own colors is super tricky, but that that instead gets a bit easier.

So thats a nice feature which should make Flutter apps more customizable in the future.

We then also got a list of some breaking changes.

So, adjustments you might need to make to your code to make sure that it still works with Flutter.

And for example, we got some deprecated APIs, which were deprecated in the past, which now should be removed with the release of Flutter 3.

Now we find a list of those removed APIs here, and there are some niche APIs.

The most important API that seems to be removed right now are the old buttons; flat button, raised button, outline button.

Im saying seems because at least for me, I upgraded to Flutter 3 and I created a new Flutter project, and I was able to use those old buttons without issues in there.

Sure, I got the deprecation warning, but I was able to still use them.

So maybe they werent really removed or they forgot it, whatever.

You can of course easily switch to those new buttons.

For example to switch from raised button to elevated button, its basically a code change like this.

And if you had some styling or a custom color attached to the raised button, then switching is as easy as setting the style value, style argument for the new button, and then setting it to a style like this.

You also have an official migration guide which you find here, which gives you all the details about those new buttons and how to migrate your code from the old buttons to these new buttons.

And that is basically it.

We got more removals here, as I said, many of them for niche configurations or features, which you might have not used too often.

Noteworthy is probably the Scaffold change here that you should use Scaffold Messenger instead of Scaffold now, if you wanna show a SnackBar, but thats a really tiny change.

Its just the name that changed as you can see here.

But other than that, there arent any major changes for Flutter developers that are primarily targeting mobile.

Now dont get me wrong.

Flutter 3 is a major milestone because being able to use one at the same code base with minor adjustments in the code maybe, to then ship applications for all platforms, mobile, desktop, and web is huge.

And Flutter got so far over the last years.

Thats really amazing. It is an amazing technology.

Im personally not that much into desktop application development, but just because Im not does not mean that no one is of course.

And if you are interested in building cross-platform desktop applications, then Flutter 3 of course is a major step forward, and you might wanna play around with it to explore how you can build desktop applications for macOS, Linux, and Windows with it.

If youre primarily interested into mobile development, then its probably some future release of Flutter that gives us more nice features, like Material 3 support.

Academind: Flutter 3 - Whats New For Mobile App Developers? - Mobile App Development