How to prevent Visual Studio Code Flutter/Dart Editor from formatting new line/wrapping code?

1,293

Follow the instructions below:

  1. Open Settings.
  2. Expand Extensions and click Dart & Flutter on the left.
  3. Find Dart: Line Length.
  4. Change it to the value you want.

enter image description here

Share:
1,293
khalid Saud
Author by

khalid Saud

Updated on December 28, 2022

Comments

  • khalid Saud
    khalid Saud over 1 year

    I recently started working on Flutter/Dart, I like the flutter autoformatting on-save, but one thing might or might not be related is the code wrapping for long code even if code is still fitting my 4k editor window.

    Is there a way to prevent new line but keep the comma auto format?

    Thanks

    example of code auto formatted to new line

    .vscode/settings.sjon