a15a9d395ee9e6714f599cb1bfee44740beb55aff36f6f3c07b1acffded66709a216be37e1a5ff64f5a75eda308278c753f14cafd3d0bde8f0212330acb7cf 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. # duplexer
  2. [![build status][1]][2] [![dependency status][3]][4]
  3. [![browser support][5]][6]
  4. Creates a duplex stream
  5. Taken from [event-stream][7]
  6. ## duplex (writeStream, readStream)
  7. Takes a writable stream and a readable stream and makes them appear as a readable writable stream.
  8. It is assumed that the two streams are connected to each other in some way.
  9. ## Example
  10. ```js
  11. var cp = require('child_process')
  12. , duplex = require('duplexer')
  13. , grep = cp.exec('grep Stream')
  14. duplex(grep.stdin, grep.stdout)
  15. ```
  16. ## Installation
  17. `npm install duplexer`
  18. ## Tests
  19. `npm test`
  20. ## Contributors
  21. - Dominictarr
  22. - Raynos
  23. - samccone
  24. ## MIT Licenced
  25. [1]: https://secure.travis-ci.org/Raynos/duplexer.png
  26. [2]: https://travis-ci.org/Raynos/duplexer
  27. [3]: https://david-dm.org/Raynos/duplexer.png
  28. [4]: https://david-dm.org/Raynos/duplexer
  29. [5]: https://ci.testling.com/Raynos/duplexer.png
  30. [6]: https://ci.testling.com/Raynos/duplexer
  31. [7]: https://github.com/dominictarr/event-stream#duplex-writestream-readstream