My Node.js Express + CoffeeScript setup

Last week I blogged about some of the reasons I like to use Node.js for Web development.

Today I thought I’d share some details  on how I start new projects with Express.js and CoffeeScript. Writing this post also helped me review and improve my workflow a bit which is always nice.

Basic setup

I start by creating a new express project and converting it to use CoffeeScript. To do so, we’ll need to install express, coffee-script and js2coffee globally:

npm install -g express coffee-script
npm install -g git://

The official js2coffee module being currently broken, I forked it and applied 2 pull requests (#194 and #183) in my own fork to make it work with recent versions of CoffeeScript and on Windows. When those are merged upstream, I’ll be able to revert back to install js2coffee with:

npm install -g js2coffee

Continue reading