Simple asynchronous/synchronous hooks for Node.JS and browsers