Rewrite the javascript to follow RxJS integration pattern
Added integration test with rx.time
Reorg doc