reworked js to litcoffee