Adds array.last property. Usage: ['a', 'b'].last //=> 'b'
Install with npm:
$ npm install array-prototype-last --save
require('array-prototype-last');
[1, 2, 3].last; //=> 3
[].last; //=> undefined
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Install dev dependencies:
$ npm install -d && npm test
Alex Ishenko
Copyright © 2017 Alex Ishenko Released under the MIT license.