What’s new in Flutter 1.2
Ongoing vision with Flutter is to provide a portable toolkit for building stunning experiences wherever you might want to paint pixels on the screen. With every release, we continue to push towards ensuring that Flutter is fast, beautiful, productive and open for every platform we support. In Flutter 1.20, which is released today to our stable channel, Flutter has improvements for every one of these four pillars.
Autofill for mobile text fields
One of the #1 most requested Flutter features for a while has been to support the underlying Android and iOS support for text autofill in Flutter programs. With PR 52126, we’re pleased to say that the wait is over — no more asking your users to re-enter data that the OS has already gathered for them.
You’ll be pleased to hear that we’ve already started adding this functionality for the web, as well.
A new widget for common patterns of interaction
This release introduces a new widget, the InteractiveViewer. The InteractiveViewer is designed for building common kinds of interactivity into your app, like pan, zoom, and drag ‘n’ drop, even in the face of resizing, which this simple Go board sample demonstrates.
To see how to integrate the InteractiveViewer into your own app, check out the API documentation where you can play with it in DartPad. Also, if you’d like to hear about how the InteractiveViewer was designed and developed, you can see a presentation by the author for Chicago Flutter on YouTube.
If you’re interested in adding the kind of interactivity to your Flutter app that InteractiveViewer enables, then you’ll probably also be happy to hear that we’ve added more capabilities to drag ‘n’ drop in this release. Specifically, if you’d like to know precisely where the drop happened on the target widget (it’s always been available to the Draggable object itself), now you can get that information with the DragTarget onAcceptDetails method.
New drag target accept details in action
Check out this sample for the details and look forward to a future release that will make this information available during the drag as well so that the DragTarget can more easily provide visual updates during a drag operation.
Updated Material Slider, RangeSlider, TimePicker, and DatePicker
In addition to new widgets, this release includes a number of updated widgets to match the latest Material guidelines. These include Slider and RangeSlider. For more information, see What’s new with the Slider widget?
updated Material Slider
DatePicker has been updated to include a new compact design as well as support for date ranges.
And finally, TimePicker has a completely new style.
If you’d like to play around with it, here’s a fun web demo built with Flutter.
Responsive Licenses page
Another update this release is the new responsive licenses page available from the AboutDialog.
PR 57588, from community contributor TonicArtos, is not only updated to match Material guidelines, making it just plain nice to look at, but it’s easier to navigate and designed to work as well on tablets and desktops as on phones. Thanks, TonicArtos! Since every Flutter app should be showing the licenses for the packages they’re using, you just made every Flutter app better!
New pubspec.yaml format required for publishing plugins
Of course, Flutter isn’t just the widgets; it’s also the tooling and this release comes with too many updates to mention. However, here are some of the highlights.
First and foremost, a public service announcement: if you’re a Flutter plugin author, then the legacy pubspec.yaml format is no longer supported for publishing plugins. If you try, you’ll get the following error message when executing pub publish:
The old format did not support specifying which platforms your plugins support, and has been deprecated since Flutter 1.12. The new pubspec.yaml format is now required for publishing new or updated plugins.
For clients of plugins, the tools still understand the old pubspec format and will for the foreseeable future. All existing plugins on pub.dev using the legacy pubspec.yaml format will continue to work with Flutter apps for the foreseeable future.
Preview of embedded Dart DevTools in Visual Studio Code
The biggest tooling update in this release comes to the Visual Studio Code extension, which provides a preview of a new feature to enable you to bring Dart DevTools screens directly into your coding workspace.
Preview of Layout Explorer from Dart DevTools embedded into Visual Studio Code
Enable this feature with the new dart.previewEmbeddedDevTools setting. The above screenshot shows the Flutter Widget Inspector embedded directly into Visual Studio Code but with this new setting enabled, you can choose your favorite page embed using the Dart DevTools menu on the status bar.
This menu allows you to choose which pages to show.
This feature is still in preview, so let us know if you have any trouble with it.
Updates to network tracking
The latest version of Dart DevTools comes with an updated version of the Network page that enables web socket profiling.
Timing, status and content type of socket connections on the Network page of Dart DevTools
The Network page now adds timing information to the network calls from your app, along with other information like status and content type. Additional improvements have been made to the details UI to provide an overview of the data in a websocket or http request. We’ve also got more plans for this page to include HTTP request/response bodies and monitoring gRPC traffic.
Updating import statements on file rename
Another new feature for Visual Studio Code is updating imports on rename, which automatically updates import statements when files are moved or renamed.
moving Dart files in Visual Studio Code updates the import statements
This feature currently only works for single files and not multiple files or folders, but that support is coming soon.
For more information and to develop mobile apps using Flutter, Hire Flutter Developer from us as we give you a high-quality product by utilizing all the latest tools and advanced technology. E-mail us any clock at – email@example.com or Skype us: “hkinfosoft”. To develop Mobile Apps using Flutter, please visit our technology page.