Skip to content

Instantly share code, notes, and snippets.

@burdiuz
Last active October 28, 2016 20:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save burdiuz/0d25701dcc16f80c93aecf371dd57c0e to your computer and use it in GitHub Desktop.
Save burdiuz/0d25701dcc16f80c93aecf371dd57c0e to your computer and use it in GitHub Desktop.
Simple HTTP server for static files using express
/**
node server
http://localhost:8081
*/
(function(express){
this.use(express.static('.'));
this.listen(8081, function(){
console.log('Server started...');
});
}).apply(require('express')(), [require('express')]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment