You may be here because you're reading the Apress PRO AngularJS
book...
As is described in a comment to this question by KnarfaLingus
:
[START QUOTE]
The connect module has been reorganized. do:
npm install connect
and also
npm install serve-static
Afterward your server.js
can be written as:
var connect = require('connect');
var serveStatic = require('serve-static');
var app = connect();
app.use(serveStatic('../angularjs'));
app.listen(5000);
[END QUOTE]
Although I do it, as the book suggests, in a more concise way like this:
var connect = require('connect');
var serveStatic = require('serve-static');
connect().use(
serveStatic("../angularjs")
).listen(5000);