There are two important settings in VS Code that control line wrapping.
editor.wrappingColumn
(300 by default)- and
editor.wordWrap
(false by default)
It is important to understand the need for two distinct settings and how to tweak them to suit your use-case:
Examples (with explanations):
wordWrap |
wrappingColumn |
Explanation |
---|---|---|
false | 300 | Lines will wrap at 300 |
false | 0 | Lines will wrap at viewport_column |
false | -1 | Lines will never wrap. |
true | 300 | Lines will wrap at min(viewport_column, 300) |
true | 0 | Lines will wrap at viewport_column |
true | -1 | Lines will never wrap. |