4 ms·
How does it encourage to use extra variables? If you have a variable with the name use it, otherwise do whatever you usually do like calling a function. It does
by kevindqc 9y ago
How does it encourage to use extra variables? If you have a variable with the name use it, otherwise do whatever you usually do like calling a function. It doesn't encourage doing something like
const id = getId();
let obj = {id, otherProp: 'something'};
vs
let obj = {id: getId(), otherProp: 'something'};
?
- bpicolo 9y agoRight. The real argument is I don't like the additional ambiguity. For me, it doesn't seem like a particularly ergonomic syntax choice.