I found this really cool tool to create Regular JavaScript from C#. You can find it here Script#.

Other then that there is not much more to say other then trying out this cool tool. It has been mentioned that Microsoft has used this tool to create some of the JavaScript found in SHarePoint2010.