vscode-dart-import
vscode-dart-import copied to clipboard
Parsing fails for files with comments before import statements
Hi, thanks for the nice extension!
There is an issue with files that have comments before the import statements, for example source file headers such as:
/*
* File: xyz.dart
* Project: ABC
* Created: 2021-05-06 14:15:51
*/
import 'file.dart';
Parsing stops if the first non-empty line is not an import statement which means no import fixing will be done on files like these.
https://github.com/luanpotter/vscode-dart-import/blob/28c375f14c8f0d87e96c6af567dacee91523143c/src/main.ts#L47-L49
Changing line 48 to continue;
should fix it.
Me too.