Javascript K combinator

You may find this post useful too - it explains how callbacks are also used for async event handing