DEV Community

Discussion on: `at` coming soon to ECMAScript

Collapse
 
rosostolato profile image
rosostolato

It will be useful if it can access not just last but also the length - k item with arr.at(-k). For example arr.at(-3). If it's just for the last one, it won't be that good.

Collapse
 
laurieontech profile image
Laurie

Yes, any negative index works.