A minimal, isomorphic process.nextTick implementation.
node: process.nextTick
browser: setImmediate || setTimeout
This module is essentially just-next-tick. The difference is, iso-next-tick can be browserified without pulling in the process
object (see: insert-module-globals).
$ npm install iso-next-tick
var nextTick = require('iso-next-tick')
nextTick(function () {
console.log('world')
})
console.log('hello')
> hello
> world
BSD