I started using the Vim extension for VS Code. I want to make my line numbers display like they do for me in Neovim, but I couldn't find any solution for it.
Asked
Active
Viewed 28 times
-2
-
search settings for `line number` – rioV8 Aug 20 '23 at 17:55
-
Note that the answer to this question can also be found in [Relative line numbers in Visual Studio](/q/4967217/11107541), but I believe that's the wrong place for that answer to go, since that question is about Visual Studio and not VS Code, so I have chosen for my self not to vote this question as a duplicate of that one. – starball Aug 20 '23 at 21:27
1 Answers
0
Use the editor.lineNumbers
setting and set it to "relative"
.
Ex. in settings.json:
"editor.lineNumbers": "relative"
The setting reads as follows in the default settings:
// Controls the display of line numbers. // - off: Line numbers are not rendered. // - on: Line numbers are rendered as absolute number. // - relative: Line numbers are rendered as distance in lines to cursor position. // - interval: Line numbers are rendered every 10 lines. "editor.lineNumbers": "on",>

starball
- 20,030
- 7
- 43
- 238