millermedeiros / esformatter

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

Space in nested objects #442

Closed maitriyogin closed 8 years ago

maitriyogin commented 8 years ago

Hi, I want to remove spaces in nested components, mainly for react props. this {{ marginLeft: 20, marginRight: 20 }} should be {{marginLeft: 20, marginRight: 20}}

I'v tried fiddling with whitespace.before.ObjectExpressionClosingBrace=0 and whitespace.after.ObjectExpressionOpeningBrace=0. This works great for un-nested components but not for nested components. any ideas on what properties I need to set? /Stephen.

millermedeiros commented 8 years ago

are you using the esformatter-jsx plugin?

looks like they don't support this feature yet (they convert line breaks into a single space, maybe that's the issue), would probably create a feature request there

maitriyogin commented 8 years ago

Hi, Yeah, I'am .. Ok ill post sondering there. Cheers, /Stephen

Sent from my iPhone

On 5 juni 2016, at 09:13, Miller Medeiros notifications@github.com i:

are you using the esformatter-jsx plugin?

looks like they don't support this feature yet (they convert line breaks into a single space, maybe that's the issue), would probably create a feature request there

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.