You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When an import statement being splitted in multiple lines (eg. because exceeding the default 80 characters with show or hide on any long import) the tool moves these lines to the end of the import list. It seems these import statements are not recognized, so they are put in afterImportLineshere.
To Reproduce
For example add flutter_local_notifications as a dependency, as this package will result quite long import lines.
Import the package and let's say you want to hide a type (eg. because you have one with the same name in your current file already).
After saving (if you have autoformat on) or formatting (eg. with dart format . or flutter format .) this line is splitted to two, since its length is 110 characters (default and recommended max line length is 80 chars).
Describe the bug
When an import statement being splitted in multiple lines (eg. because exceeding the default 80 characters with
show
orhide
on any long import) the tool moves these lines to the end of the import list. It seems these import statements are not recognized, so they are put inafterImportLines
here.To Reproduce
For example add flutter_local_notifications as a dependency, as this package will result quite long import lines.
Import the package and let's say you want to hide a type (eg. because you have one with the same name in your current file already).
After saving (if you have autoformat on) or formatting (eg. with
dart format .
orflutter format .
) this line is splitted to two, since its length is 110 characters (default and recommended max line length is 80 chars).When running the import_sorter command, this import line "pair" is moved after all other imports.
Expected behavior
Move multiline imports to the section they belong to.
Meta Information:
import_sorter
Version: 4.4.1The text was updated successfully, but these errors were encountered: