# cocat

> Node module for asynchronous CSS file concatenation

Latest version **0.2.0** (published 2013-03-16) · 0 weekly downloads

## Install

```sh
npm install cocat
pnpm add cocat
yarn add cocat
bun add cocat
```

Provides the command `cocat`.

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.0 |
| Published | 2013-03-16 |
| First published | 2012-03-24 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=0.6.0 |
| Dependencies | 3 |
| Known vulnerabilities | 0 (+2 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Tristan Blease |
| Maintainers | thetristan |

## Links

- npm: https://www.npmjs.com/package/cocat
- Repository: https://github.com/thetristan/cocat
- Homepage: http://github.com/thetristan/cocat
- npm.io page: https://npm.io/package/cocat

## Dependencies (3)

- [async](https://npm.io/package/async.md) ~0.2.6
- [commander](https://npm.io/package/commander.md) ~1.1.1
- [underscore](https://npm.io/package/underscore.md) ~1.4.4

## Recent versions

- 0.2.0 (latest) — 2013-03-16
- 0.1.1 — 2012-03-24
- 0.1.0 — 2012-03-24

## README

# Cocat

Node module for asynchronous CSS file concatenation. Looks for @import statements and replaces them with the actual content of the file if it exists, otherwise it just leaves the @import statement as-is.

### Usage

Use it in your scripts by specifying a file

```javascript
Cocat = require('cocat');
Cocat.concat({
  filename: 'path_to_file.css'
}, function(err, output) {
  // ...
});
```

Or by specifying a string and a path to use instead

```javascript
Cocat = require('cocat');
Cocat.concat({
  content: '/* CSS GOES HERE */'
  path:    '../foo/bar/'
}, function(err, output) {
  // ...
});
```

It also works great on the command line:

```
Usage: cocat [options] input.css [output.css]

Options:

  -h, --help     output usage information
  -V, --version  output the version number
  -s, --save     save output to a file based on the inputfile name
```

Examples:

```
$ cocat bar.css          # concats and ouputs to stdout
$ cocat -s foo.css       # concats and saves to foo.concat.css
$ cocat baz.css qux.css  # concats and saves to qux.css
```

Happy concatenating!

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