3 ms·
Maybe Java should catch some inspiration from the spread operator from JavaScript? In JS you would write {...p, x: p.x * 2}
by throwaway4good 6y ago
Maybe Java should catch some inspiration from the spread operator from JavaScript? In JS you would write {...p, x: p.x * 2}
- i386 6y agoThe worst language feature. Always used at the detriment of readability.
- rualca 6y agoReact hooks disprove the hypothesis that javascript's spread operator has a negative impact on readability. Moreover, to argue against the spread operator, first you need to argue in favour of array indexing in terms of readability.