UNPKG

makemehapi

Version:

Self guided workshops to teach you about hapi.

20 lines (14 loc) 313 B
var Hapi = require('hapi'); var server = new Hapi.Server(); server.connection({ host: 'localhost', port: Number(process.argv[2] || 8080) }); server.route({ method: 'GET', path: '/', handler: function (request, reply) { reply('Hello Hapi'); } }); server.start(function () {});