Skip to content

Instantly share code, notes, and snippets.

@rsdiaz
Last active April 28, 2016 18:56
Show Gist options
  • Save rsdiaz/ccfaacc7031df09c917df8ba0a12ff9c to your computer and use it in GitHub Desktop.
Save rsdiaz/ccfaacc7031df09c917df8ba0a12ff9c to your computer and use it in GitHub Desktop.
var express = require('express');
var router = express.Router();
/* GET pagina de inicio */
router.get('/', function(req, res, next) {
res.render('index', { title: 'Express' });
});
/* Añadimos la ruta para la pagina about */
/* GET pagina about */
router.get('/about', function(req, res, next) {
res.send('Hola desde la ruta about...');
})
module.exports = router;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment