millermedeiros / esformatter

ECMAScript code beautifier/formatter
MIT License
970 stars 91 forks source link

Tab length of 4 #436

Closed glockjt closed 8 years ago

glockjt commented 8 years ago

If there isn't already an option now, which I don't find it intuitive to do this but could there be an option to specify tab width? Currently, you can only do it with length 2.

millermedeiros commented 8 years ago

set indent.value to be 4 spaces, instead of 2: https://github.com/millermedeiros/esformatter/blob/fa0d009f34df88ce453473a06684c76017e8b66d/lib/preset/default.json#L7

or:

esformatter --indent.value="    "

https://github.com/millermedeiros/esformatter/issues/431#issuecomment-214638018