Dart-Code: Keybinding code fixes don't work

It would be very useful to have “fix all” command for linter rules. For example I have now ~400 warnings in my project for prefer_single_quotes. There is already a quick fix command “Convert to single quoted string” but it is too big task to fix all those issues one by one. I would like to fix all the warnings with a single command.

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 2
  • Comments: 21 (12 by maintainers)

Commits related to this issue

Most upvoted comments

Thank you so much for the update. Thank you for being so approachable and your effort to support us. Cheers

Ok, I figured this out. Doing toDoubleQuotedString works, but toStringleQuotedString does not, and the reason is that one comes as an “assist” and the other as a “fix”, and the two code paths aren’t the same (only one sets the ID correctly).

Working on a fix!

I have often difficulties in determining if a specific issue or a feature request is related to VS Code (Dart Code), Dart SDK or something else.

That’s very understandable, the line can be a bit blurry (for example some of the things you see in the quick-fix drop-down are synthetic and generated by the VS code extension). If in doubt, just raise things here - I’m happy to triage them and can sometimes provide additional context that would improve a bug report in the SDK/Flutter repos.

Thanks!