Skip to content

Instantly share code, notes, and snippets.

@ntreadway
Created January 30, 2013 19:17
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ntreadway/4675905 to your computer and use it in GitHub Desktop.
Save ntreadway/4675905 to your computer and use it in GitHub Desktop.
Express server for deploying to Heroku with Angular.
var express = require("express"),
app = express.createServer(express.logger());
port = process.env.PORT || 3000;
app.configure(function(){
app.use(express.methodOverride());
app.use(express.bodyParser());
app.use(express.static(__dirname + '/'));
app.use(express.errorHandler({
dumpExceptions: true,
showStack: true
}));
app.use(app.router);
});
app.listen(port);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment