nyc-bookstores/node_modules/ecstatic/example/express.js

10 lines
262 B
JavaScript
Raw Normal View History

2013-05-27 20:45:59 +00:00
var express = require('express');
var ecstatic = require('../lib/ecstatic');
var http = require('http');
var app = express();
app.use(ecstatic(__dirname + '/public', { showdir : true }));
http.createServer(app).listen(8080);
console.log('Listening on :8080');