Skip to content

Feature Request: Easier ways to Optimize imports #1862

@brianegan

Description

@brianegan

Hey all, @pq had an interesting PR against a project of mine: helping me sort imports.

I realized: Is there any way we could make this easier for end users? For example, Java has the "Optimize Imports on the fly" functionality. Is that possible for Dart?

Btw, the fact I'm asking about these nitty-gritty details shows how good the plugin is getting! Thanks again for all the hard work :)

Idea 1: Optimize Imports on the Fly

In IntelliJ, you can find the setting under Editor > General > Auto-import > "Optimize Imports on the Fly", but the option is only available for Java in my Editor.

screen shot 2018-03-01 at 3 07 56 pm

Idea 2: Automatically run "Optimize Imports" on format

You can manually enable this option, but it might be neat if it was enabled for ya by default!

Screenshots of how to enable:

screen shot 2018-03-01 at 12 13 53 pm

screen shot 2018-03-01 at 12 13 57 pm

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions