# co-cat

> Concatenate co generator streams

Latest version **0.1.2** (published 2014-02-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install co-cat
pnpm add co-cat
yarn add co-cat
bun add co-cat
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2014-02-10 |
| First published | 2014-02-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Maintainers | juliangruber |

## Links

- npm: https://www.npmjs.com/package/co-cat
- Repository: https://github.com/juliangruber/co-cat
- Issues: https://github.com/juliangruber/co-cat/issues
- npm.io page: https://npm.io/package/co-cat

## Recent versions

- 0.1.2 (latest) — 2014-02-10
- 0.1.1 — 2014-02-09
- 0.1.0 — 2014-02-09
- 0.0.0 — 2014-02-09

## README

# co-cat

  Concatenate [co generator streams](https://github.com/juliangruber/co-stream).

  [![build status](https://secure.travis-ci.org/juliangruber/co-cat.png)](http://travis-ci.org/juliangruber/co-cat)

## Example

```js
var cat = require('co-cat');
var co = require('co');

co(function*(){
  var read = cat(twice('foo'), twice('bar'), twice('baz'));
  var data;
  while (data = yield read()) console.log(data);
})();

function twice(str){
  var i = 0;
  return function*(end){
    if (end) return;
    if (++i <3) return str;
  }
}
```

  Outputs:

```bash
$ node --harmony example
foo
foo
bar
bar
baz
baz
```

## Installation

```bash
$ npm install co-cat
```

## API

### cat(stream, ..)
### cat(streams)

  Concatenate an array of streams of each arg stream and return a stream.

## License

  MIT

---
_Source: https://npm.io/package/co-cat · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
