# tachyons-build-optimal-css

> Transpile Tachyons PostCSS to vanilla CSS. This build process also removes comments, autoprefixes, and has options for minifying the output or repeating class selectors (to play nice with overly specific CSS frameworks).

Latest version **1.1.0** (published 2016-09-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install tachyons-build-optimal-css
pnpm add tachyons-build-optimal-css
yarn add tachyons-build-optimal-css
bun add tachyons-build-optimal-css
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.0 |
| Published | 2016-09-15 |
| First published | 2016-09-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 12 |
| Known vulnerabilities | 0 (+6 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | David Mark Clements |
| Maintainers | davidmarkclements |

## Links

- npm: https://www.npmjs.com/package/tachyons-build-optimal-css
- Repository: https://github.com/davidmarkclements/tachyons-build-optimal-css
- Homepage: https://github.com/davidmarkclements/tachyons-build-optimal-css#readme
- Issues: https://github.com/davidmarkclements/tachyons-build-optimal-css/issues
- npm.io page: https://npm.io/package/tachyons-build-optimal-css

## Dependencies (12)

- [cssnano](https://npm.io/package/cssnano.md) ^3.7.4
- [postcss](https://npm.io/package/postcss.md) ^5.2.0
- [autoprefixer](https://npm.io/package/autoprefixer.md) ^6.4.1
- [css-mqpacker](https://npm.io/package/css-mqpacker.md) ^5.0.1
- [perfectionist](https://npm.io/package/perfectionist.md) ^2.3.0
- [postcss-import](https://npm.io/package/postcss-import.md) ^8.1.2
- [postcss-class-repeat](https://npm.io/package/postcss-class-repeat.md) ^0.1.0
- [postcss-conditionals](https://npm.io/package/postcss-conditionals.md) ^2.0.2
- [postcss-custom-media](https://npm.io/package/postcss-custom-media.md) ^5.0.1
- [postcss-css-variables](https://npm.io/package/postcss-css-variables.md) ^0.5.2
- [postcss-class-whitelist](https://npm.io/package/postcss-class-whitelist.md) ^1.0.1
- [postcss-discard-comments](https://npm.io/package/postcss-discard-comments.md) ^2.0.4

## Recent versions

- 1.1.0 (latest) — 2016-09-15
- 1.0.1 — 2016-09-15
- 1.0.0 — 2016-09-15

## README

# tachyons-build-optimal-css

Transpile Tachyons PostCSS to vanilla CSS, optionally supply a whitelist
for optimal CSS output.

This build process also removes comments, autoprefixes, and has options for minifying the output or repeating class selectors (to play nice with overly specific CSS frameworks).

## Installation

```bash
npm install --save-dev tachyons-build-optimal-css
```

## Usage

```javascript
const fs = require('fs')
const build = require('tachyons-build-optimal-css')

const input = fs.readFileSync('input.css', 'utf8')

build(input, {
  from: 'input.css',
  to: 'output.css',
  minify: false,
  whitelist: ['w4', 'w2', 'mw4'],
  stripComments: true
}).then(result => {
  fs.writeFileSync('output.css', result.css)
})
```

#### Options

| Option | Default | Description | Values |
| ------ | ------- | ----------- | ------ |
| `from` | `undefined` | The input file name | file name |
| `to` | `undefined` | The output file name | file name |
| `minify` | `false` | Minify the output CSS, infers stripComments | `true`, `false` |
| `repeat` | `false` | Whether to repeat classes in selectors | `1..10` |
| `whitelist` | `[]` | Restrict output CSS to whitelist | tachyons classes |
| `stripComments` | `false` | strip comments | `true`, `false` |

## License

MIT

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