data.task
¶Stability: | 3 - Stable |
---|---|
Bug Tracker: | https://github.com/folktale/data.task/issues |
Version: | 3.0.0 |
Repository: | https://github.com/folktale/data.task |
Portability: | Portable |
npm package: | data.task |
A structure for time-dependent values, providing explicit effects for delayed computations, latency, etc.
Require the data.task
package, after installing it:
var Task = require('data.task')
This gives you back a data.task.Task
object.
This structure allows one to model side-effects (specially time-based ones) explicitly, such that one can have full knowledge of when they’re dealing with delayed computations, latency, or anything that isn’t pure or can be computed immediately.
A common use of this structure is to replace the usual Continuation-Passing Style form of programming in order to be able to compose and sequence time-dependent effects using the generic and powerful monadic operations.
Data.Task
can be used to model time-dependent
values.