// This loads the http module var http = require('http'); // This configures our http server var server = http.createServer(function (request, response) { // Called once the server has started
response.end() }); // Listen on port 3000, IP defaults to 127.0.0.1 or localhost server.listen(3000); // Log what is happening, so we can see it in terminal console.log("Server running at http://127.0.0.1:3000/");
var myLibrary = require('./mylibrary')
module.exports = function(){
console.log('Hello from My Library!')
};
//When I go to my root domain in the browser, render the index view
app.get('/', function(req, res){
res.render 'index'
});