2023 Flutter and VSCode.

2023-01-14

Flutter developers have a few IDEs to choose from with VSCode being a popular choice, and the one I’ve chosen. Recently I wrote about my favorite extensions for Flutter, in this post I’m listing a few non obvious features to help make the most of VSCode and Flutter together.

Commands

dart format . Fix code formatting in all files.

dart analyze Lint all code.

dart fix --dry-run Fix those lints

flutter pub upgrade --major-versions Just what it says on the tin. Get the latest of all packages.

Shortcuts

Shift-Alt-O will organize all your Flutter imports in a jiffy, you never need to do it by hand again.

Ctrl-Space Forces the autocomplete menu to pop up.

Ctrl-. Forces the list of code action menu to pop up. ie: Refactoring menu.

Code Snippets. check your extensions.

F5 Start debugging.

Alt-Shift-F Format code now.

More?

As I find them I’ll update this page.