Array.prototype.last()

Dmitry Soshnikov dmitry.soshnikov at gmail.com
Tue May 13 12:25:36 PDT 2014


Thanks for the info, Rick

Yeah, I know it's closed, that's why mentioned that then probably for ES7.
Just thought, the addition is so trivial, that could possibly and easily be
included to ES6.

Although, taking into account some stylistics questions (getter vs method,
and the name), probably it's not that trivial, and would require time to
discuss. So, yeah, a detailed proposal seems is better way to go.

Dmitry


On Tue, May 13, 2014 at 12:16 PM, Rick Waldron <waldron.rick at gmail.com>wrote:

> I agree, this is a reasonable addition, however:
>
>
> On Tue, May 13, 2014 at 2:54 PM, Dmitry Soshnikov <
> dmitry.soshnikov at gmail.com> wrote:
>
>> Hi,
>>
>> Exactly at the moment I'm writing too many of
>>
>>   entries[entries.length - 1]
>>
>> where `entries` is an array (with of course moving to a helper
>> function/prototype method).
>>
>> Will it make sense to add it now to ES6?
>>
>
> No, ES6 is closed for all new features—but you should absolutely write up
> a proposal (gist is fine, here are examples:
> https://gist.github.com/rwaldron/11186883,
> https://gist.github.com/WebReflection/9353781) and submit a PR to:
> https://github.com/tc39/ecma262
>
> Rick
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20140513/9a5c0036/attachment.html>


More information about the es-discuss mailing list