mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-07 10:07:48 +00:00
Cleanup doc note on lazy evaluation. [ci skip]
This commit is contained in:
17
lodash.js
17
lodash.js
@@ -1386,17 +1386,16 @@
|
|||||||
* Explicit chaining, which must be unwrapped with `_#value` in all cases,
|
* Explicit chaining, which must be unwrapped with `_#value` in all cases,
|
||||||
* may be enabled using `_.chain`.
|
* may be enabled using `_.chain`.
|
||||||
*
|
*
|
||||||
* The execution of chained methods is lazy, that is, execution is deferred
|
* The execution of chained methods is lazy, that is, it's deferred until
|
||||||
* until `_#value` is implicitly or explicitly called.
|
* `_#value` is implicitly or explicitly called.
|
||||||
*
|
*
|
||||||
* Lazy evaluation allows several methods to support shortcut fusion. Shortcut
|
* Lazy evaluation allows several methods to support shortcut fusion. Shortcut
|
||||||
* fusion is an optimization strategy which merge iteratee calls; this can help
|
* fusion is an optimization to merge iteratee calls; this avoids the creation
|
||||||
* to avoid the creation of intermediate data structures and greatly reduce the
|
* of intermediate arrays and can greatly reduce the number of iteratee executions.
|
||||||
* number of iteratee executions. Sections of a chain sequence may qualify for
|
* Sections of a chain sequence qualify for shortcut fusion if the section is
|
||||||
* shortcut fusion if the section is applied to an array of at least two hundred
|
* applied to an array of at least two hundred elements and any iteratees
|
||||||
* elements and any iteratees or predicates accept only one argument. The
|
* accept only one argument. The heuristic for whether a section qualifies
|
||||||
* heuristic for whether a section qualifies for shortcut fusion is subject
|
* for shortcut fusion is subject to change.
|
||||||
* to change.
|
|
||||||
*
|
*
|
||||||
* Chaining is supported in custom builds as long as the `_#value` method is
|
* Chaining is supported in custom builds as long as the `_#value` method is
|
||||||
* directly or indirectly included in the build.
|
* directly or indirectly included in the build.
|
||||||
|
|||||||
Reference in New Issue
Block a user