@f/foreach
Fast for each.
Last updated 10 years ago by f .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @f/foreach 
SYNC missed versions from official npm registry.

foreach

Build status Git tag NPM version Code style

Fast for each.

Installation

$ npm install @f/foreach

Usage

var foreach = require('@f/foreach')

var obj = {a: 1, b: 2}
var copy = {}

foreach(function (val, key) {
  copy[key] = val
})

copy // => {a: 1, b: 2}

API

foreach(fn, obj)

  • fn - iterator
  • obj - object to iterate over

License

MIT

Current Tags

  • 1.2.2                                ...           latest (10 years ago)

3 Versions

  • 1.2.2                                ...           10 years ago
  • 1.2.1                                ...           10 years ago
  • 1.2.0                                ...           10 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (4)
Dev Dependencies (2)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |