UNPKG

268 BJavaScriptView Raw
1"use strict";
2
3/**
4 * Call a function later.
5 * @param {Function} fn function to call
6 * @param args Can also specify 0 or more arguments to call function with.
7 */
8function defer(fn, args)
9{
10 fn && process.nextTick(fn.bind(...arguments));
11}
12
13module.exports = defer;