My take on some javascript.