coffeescript
and some changes for conversion