IMHO it's the part of the language. It is there to save a ton of time and help us to write less code. After using a while, it gets easy to read/understand them. I get responses from many developers that they are uncomfortable with it, it makes things them unreadable. What is your opinion?
A few examples:
const { items, items : { byId, allIds }, toRename : renamed } = props
const actionCreator = dispatch => id => dispatch({ type : 'act', id })
Personally I am always targeting the browser environment whenever I write HTML, CSS, or JavaScript which means in the past I was limited to ES5.
I didn't see much use in writing ES6 only to have to transpile it down to much more ES5 that I wouldn't even be seeing and trust that if there were any bugs or problems I'd be able to figure out if it was my compile that was bad, my tools, or my own source code, etc. I don't see the advantage to targeting ahead of browser support for the browsers you are writing for.
However, as time moves on and browsers gain many ES6 features natively, we should be adopting these features and not transpiling them. The reason? Because newer ES6 features, even when they look like a little bit of syntactic sugar for something in ES5 have usually been designed in a way that's more conducive to optimization.
If you transpile these ES6 features down to ES5 for any browser that supports the ES6 feature it will still work, you're just doing extra work to actively throw away the recent optimizations we've been able to make.
So - you shouldn't be afraid of, or shy about using new ES6 features, but keep in mind the optimizations available for the features that are supported in the browsers you are targeting :D
Change is uncomfortable, no two ways about that.
We're all well versed with ES5 and when you see the ES6 Nazis suddenly dropping arrow functions all over your code, you're bound to become confused and angry.
Just read the ES6 specs and understand what they're about; you'll start liking them post that. Then, you can start using them all over your code too and join the ES6 Nazi party :P
Tommy Hodgins
CSS & Element Queries
j
stuff ;)
I think they are awesome, as you mentioned the are syntactic sugar that saves you a lot of writing. Like every syntax change it takes time to get used to but i definitly agree in general.