diff options
Diffstat (limited to 'lib/utils.coffee')
| -rw-r--r-- | lib/utils.coffee | 6 | 
1 files changed, 6 insertions, 0 deletions
| diff --git a/lib/utils.coffee b/lib/utils.coffee index 5d9696e1..07528714 100644 --- a/lib/utils.coffee +++ b/lib/utils.coffee @@ -183,6 +183,12 @@ Utils =        return true if re.test string      false +  # Convenience wrapper for setTimeout (with the arguments around the other way). +  setTimeout: (ms, func) -> setTimeout func, ms + +  # Like Nodejs's nextTick. +  nextTick: (func) -> @setTimeout 0, func +  # This creates a new function out of an existing function, where the new function takes fewer arguments. This  # allows us to pass around functions instead of functions + a partial list of arguments. | 
