Ok, I have a problem with eclipse/javascript. The identation inside of an object property is 8 spaces and it pisses me off. I want it to be 4 spaces. What do I need to change in order to fix that? I want eclipse to format it like "b".
var a = {
t: 'Hi'
};
var b = {
t: 'Hi'
};
Thanks in advance.
Eclipse Indigo (for J2EE)
Window -> Preferences -> JavaScript -> Code Style -> Formatter
then Edit...
Line Wrapping -> Expressions -> Object initializers -> Indentation policy: Indent by one
I have the same problem (also for Array).
The only thing that works for me is to disable the Smart Insert Mode (CTRL + Shift + Insert) to indent the first property, then if you enable it again it should be working properly.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With