![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/mets.corals.io/wp-content/metras.v32.1/node_modules/array-map/ |
# array-map `[].map(f)` for older browsers [](https://ci.testling.com/substack/array-map) [](http://travis-ci.org/substack/array-map) # example ``` js var map = require('array-map'); var letters = map([97,98,99], function (c) { return String.fromCharCode(c); }); console.log(letters.join('')); ``` output: ``` abc ``` # methods ``` js 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](https://npmjs.org) do: ``` npm install array-map ``` # license MIT