Open ASH-Michael opened 5 years ago
I am assuming we want trailing commas in both objects and arrays.
Some of our applications are on ecmaVersion
2015 and so will not support trailing commas in function argument lists.
Should we have a standard for that for all apps that use es2017? Do we want trailing commas to be used in function argument lists?
Should we require trailing commas when destructuring?
I don't think there should be a standard either way, personally.
I don't think there should be a standard either way, personally.
@ASH-Bryan Can you share your thoughts on this? I didn't think there was any opposition to standardizing trailing commas.
I think we should be careful how many standards we add - the more we create, the harder it will be for the team to internalize and follow them all. In my opinion we should be creating standards for things that have a real impact in some way; this feels more like a style decision to me. I'm open to being convinced otherwise!
Should we add a standard for using trailing commas in our JavaScript?
In Arrays?
In Objects?
In Functions? Only works in ecmaVersion 2017
In Array and Object Destructuring?