clean up hand transformed js sample