Dart Code
Dart & Flutter support for Visual Studio Code Discord Chat Follow on Twitter Contribute to Dart Code

For instructions on installing the Dart or Flutter extensions, go here.

v2.22.3 2019-01-31

A bug that caused Flutter’s Hot Reload to stop working if there were breakpoints in invalid locations has been fixed.

v2.22.2 2019-01-29

A bug that prevented unhandled exceptions in Dart CLI apps being shown in the debug console has been fixed.

v2.22.1 2019-01-25

The change to ignore dart binaries in your PATH that are not from the Dart SDK has been reverted because it broke handling of SDKs that came from symlinks in PATH. It will return in a future update minus the breakage.

v2.22.0 2019-01-25

Flutter: New Project From Docs

It’s now possible to create sample projects from the Flutter docs directly in VS Code with a new command Flutter: New Project From Docs.

This command will list the sample projects currently available in the docs.

Selecting a sample will automatically run flutter create --sample {sample ID} and open the project for you.

Note: This functionality requires both v2.22 of the Dart extension and v2.22 of the Flutter extension. While it’s currently possible to develop for Flutter with only the Dart extension, this may cease to be the case in future as more functionality migrates to the Flutter extension so if you haven’t already, you should install it.

Clickable Stack Trace Locations 🎉

Dart and Flutter stack traces in the Debug Console now have clickable links!

Run Test at Cursor

New commands have been added to run/debug the test for the current cursor location. The command is available in the same locations that the test CodeLens is available (the command will not be visible if your cursor is not in a valid location). For info on how to add key bindings, see here.

New Refactors

A new Extract Local Variable refactor has been added.

This extracts the code under the cursor into a variable and will allow you to type over its name.

There’s also a new Convert Method to Getter refactor to convert argument-less methods to getters.

Prompt to Launch with Errors

The preview setting from the previous release is now named dart.promptToRunIfErrors (no preview prefix) and is enabled by default. This will result in a prompt when launching if errors exist in your project.

Type Hierarchy Previews

The Show Type Hierarchy command has been updated and will now preview the relevant code as you move the selection up and down the list.

Editor Changes

Command Changes

Debugger Changes

Other Changes

Upstream Issues

Some feature requests and fixes require new features and fixes in upstream projects like VS Code and LSP which use counts of 👍s on those issues to help gauge demand. The Dart-Code website now lists some of the most significant upstream issues with a description of the feature/fix they would enable. Please consider reviewing this list and adding your 👍 to any GitHub issues relevant to features you’d like to see!