Skip to content

Instantly share code, notes, and snippets.

http = require 'http'
flow = require('../lib/conductor').conductor()
#nodes
flow.build
port: () -> 8000
listener: (port, request, response) ->
server= http.createServer (req, res) ->
request(req) if request
response(res) if response
http = require 'http'
flow = require('../lib/conductor').conductor()
#nodes
port= flow.node('port', () -> 8000)
.node('listener', (port, request, response) ->
server= http.createServer (req, res) ->
request(req) if request
response(res) if response
server.listen port)