Skip to content

Instantly share code, notes, and snippets.

@nrafter
Created February 1, 2015 12:52
Show Gist options
  • Save nrafter/6083d8c7d3e78f23870c to your computer and use it in GitHub Desktop.
Save nrafter/6083d8c7d3e78f23870c to your computer and use it in GitHub Desktop.
nodejs code to run a static file server, so that you can load resources in your single html you want to view
var connect = require('connect');
var serveStatic = require('serve-static');
connect().use(serveStatic(__dirname)).listen(8080);
console.log('displaying text so you know something happened')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment