When I write code in Visual Studio Code, and the line gets long, It doesn't break. It goes past the edge of the screen and that is rather annoying. What I want is for the line to break and then go on below, I believe this is called wrap or breaking I'm not sure. I use a split screen on my computer so only one half is my code editor and the other half is my project so I can see as I update it. Any help?
Asked
Active
Viewed 6,678 times
4
-
Try toggling word wrap with the shortcut of "Alt + Z". This would wrap a line if it goes off the screen – AnsonH Jun 24 '21 at 09:09
-
bellow is same answer [click here](https://stackoverflow.com/questions/31025502/how-can-i-switch-word-wrap-on-and-off-in-visual-studio-code) – Ata ur Rehman Jun 24 '21 at 09:37
2 Answers
3
Command
Ctrl+Shift+P
to open command palette and type wrap
there.
Windows
Alt+Z
Mac
⌥+Z

Raphaël Balet
- 6,334
- 6
- 41
- 78

Yuriy Yakym
- 3,616
- 17
- 30
0
There's a setting for that called editor.wordWrap
.
You can search the settings for "wrap" and set some additional customization to how you want VSCode to behave when wrapping text.

EcksDy
- 1,289
- 9
- 25