Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to increase size of spaces in indentation?

My indentation are too thin. But I also don't want to use more than 2 spaces for indentation. Is there a way to increase the size?

Current view,

enter image description here

Expected View,

enter image description here

like image 463
Aadarsh Patel Avatar asked Jan 17 '26 06:01

Aadarsh Patel


1 Answers

Since you aren't using any formatter type extension

You can set your indentation easily by selecting the indenting option in the status bar.

Indenting status bar

Indenting options

and then select the size you want.

If you want to globally have the same settings.

add these values to your settings.json

    "editor.tabSize": 4, //4 = 4 spaces
    "editor.detectIndentation": true, // this will auto detect whether your file is using spaces or tabs to indent. 
    "editor.insertSpaces": true, // Insert spaces when pressing Tab. This setting is overridden based on the file contents when #editor.detectIndentation# is on.

like image 195
tHeSiD Avatar answered Jan 19 '26 20:01

tHeSiD



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!