Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Map utility
JavaScript
branch: master

Merge pull request #4 from repoify/add/repository

Add repository field to readme
latest commit 46c328c72e
@jonathanong jonathanong authored
Failed to load latest commit information.
test add undefined as default
.gitignore Initial commit
Makefile Initial commit
Readme.md docs
component.json add .license property to component.json
index.js add to-function dep
package.json add repository field to readme

Readme.md

map

Map utility

Installation

$ component install component/map

API

map(array, fn)

Map returning a new array:

var names = map(users, function(user){
  return user.name;
});

map(array, string)

Map properties in string returning a new array:

var names = map(users, 'user.name');
var firstNames = map(users, 'user.name.first');

License

MIT

Something went wrong with that request. Please try again.