npm.io
0.1.0 • Published 10 years ago

cycle-http-server

Licence
MIT
Version
0.1.0
Deps
0
Vulns
0
Weekly
0

cycle-http-server

Cycle.js driver that wraps around node's http server.

Very simple example

import {run} from '@cycle/core';
import {makeServerDriver} from 'cycle-http-server';

function main({Server}) {
  Server.subscribe(function({req, res}) {
    res.end("Hello, world!");
  });
}

let drivers = {
  Server: makeServerDriver()
};

run(main, drivers);