translate frontend to coffeescript without refactoring the code