Permalink
Browse files

Doc map, reduce, forEach, filter

  • Loading branch information...
isaacs committed Jan 10, 2012
1 parent 6f6d774 commit d7723f8f504c0281c927e4d5c7a90564cb2e0ff0
Showing with 5 additions and 0 deletions.
  1. +5 −0 README.md
View
@@ -100,6 +100,11 @@ console.log(list.shift()) // foo
* `item(n)`: Retrieve the nth item in the list. This involves a walk
every time. It's very slow. If you find yourself using this,
consider using a normal Array instead.
* `map(fn, thisp)`: Like `Array.prototype.map`. Returns a new FastList.
* `reduce(fn, startValue, thisp)`: Like `Array.prototype.reduce`
* `forEach(fn, this)`: Like `Array.prototype.forEach`
* `filter(fn, thisp)`: Like `Array.prototype.filter`. Returns a new
FastList.
* `slice(start, end)`: Retrieve an array of the items at this position.
This involves a walk every time. It's very slow. If you find
yourself using this, consider using a normal Array instead.

0 comments on commit d7723f8

Please sign in to comment.