Any package that can auto space a line of code?


#1

When I type a line of code ( something like for(i=0; i <10 ; i++ ) ) in visual studio, the editor automatically puts the right length of space as soon as I add { } or ; at the end.
(e.g. for ( i = 0 ; i < 10 ; i++ ){ } ). Does anyone know if atom has a package that can do something like this? It was such a convenient function :frowning:


#2

atom-beautify will do this, but for a whole file at once, not every line as you type it. If you want, you could set up an init.coffee script to run the atom-beautify:beautify-editor on save, or even just when you stop typing. If that sounds like it would suit your needs, I can tell you how to put it together.