Dangling Commas
Any preference on dangling commas? I can go either way; I've been removing them as I see them because a majority of the codebase does not make use of them.
I took a look at the compiled app.js and the files under lib and they do not appear to contain trailing commas where the source did. So MUI should be compatible with IE8 in regards to trailing commas.
In my experience dangling commas make git diff and the life of the programmer easier, it's easy to forget to add a new commas when adding a new line (having to rebuild for nothing), it does not happens with dangling commas.
@cgestes I agree with you
Sounds like we may want to enforce dangling commas. @hai-cea what do you think?
:+1: for dangling commas.
Sounds good to me :+1:
Sweet. The eslint rule has a couple of options. I'm leaning towards always-multiline over always. This requires a dangling comma anywhere we have multiple lines in an object/array. Examples:
let obj = {
key: 'value' // valid
};
let obj = {
key: 'value', // invalid
};
let obj = {
key: 'value',
otherKey: 'value' // invalid
};
let obj = {
key: 'value',
otherKey: 'value', // valid
};
Thoughts?
I prefer always-multiline.
+1 Always multiline.