Skip to content

Commit

Permalink
Create example_app.js
Browse files Browse the repository at this point in the history
  • Loading branch information
daraser committed Dec 13, 2012
1 parent 31817c9 commit d04e881
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions example_app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
var express = require('express');
var app = express();

// load express doT
var doT = require('express-dot');

app.configure(function() {

// set views folder
app.set('views', __dirname);

// doT engine
app.set('view engine', 'dot' );
app.engine('dot', doT.__express );

});

// respond
app.get('/', function(req, res, next){
// you need to have in views folder
res.render('index', { });
});

app.listen(3000);

0 comments on commit d04e881

Please sign in to comment.