app.js
462 Bytes
var express = require('express');
var app = express();
var router = require('./router/index')(app);
var bodyParser = require('body-parser');
app.set('views', __dirname + '/views');
app.set('view engine', 'ejs');
app.engine('html', require('ejs').renderFile);
var server = app.listen(3000, function(){
console.log('helloworld');
});
app.use(express.static('public'));
app.get('/', function(req, res) {
res.render('index', { title: '또 게임해?' });
});