array-map

0.0.1 • Public • Published

array-map Version Badge

github actions coverage License Downloads

npm badge

[].map(f) for older browsers

example

var map = require('array-map');
var letters = map([97,98,99], function (c) {
	return String.fromCharCode(c);
});
console.log(letters.join(''));

output:

abc

methods

var map = require('array-map')

var ys = map(xs, f)

Create a new array ys by applying f(xs[i], i, xs) to each element in xs at index i.

install

With npm do:

npm install array-map

license

MIT

Package Sidebar

Install

npm i array-map

Weekly Downloads

599,432

Version

0.0.1

License

MIT

Unpacked Size

10.7 kB

Total Files

9

Last publish

Collaborators

  • ljharb