New syntax will always look a bit odd at first until we get used to it.

I sometimes find nested arrow functions a bit confusing to understand where
one function starts and where it ends particularly when they are one liners.
This syntax is more concise and personally I find it more readable.

Reasons for the leading dot notation is because I think it's intuitive and
also self explanatory:
1) We just remove what is in common on both ends of the expression (like
simplifying an algebraic expression).
```
const getEmail = user => user.contacts.email;
```
2) The leading dot indicates that the expression reads the property of an
object that is not statically defined.
```
const getEmail = .contacts.email;
```
_______________________________________________
es-discuss mailing list
es-discuss@mozilla.org
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to