# postcss-discard-unused-nightly

> Discard unused counter styles, keyframes and fonts.

Latest version **0.8.4** (published 2020-08-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install postcss-discard-unused-nightly
pnpm add postcss-discard-unused-nightly
yarn add postcss-discard-unused-nightly
bun add postcss-discard-unused-nightly
```

## 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.8.4 |
| Published | 2020-08-04 |
| First published | 2020-06-26 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=10.13.0 |
| Dependencies | 3 |
| Unpacked size | 8.9 KB |
| Known vulnerabilities | 0 (+5 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Anix |
| Maintainers | anixsaha |
| Keywords | css, minify, optimise, postcss, postcss-plugin, unused |

## Links

- npm: https://www.npmjs.com/package/postcss-discard-unused-nightly
- Repository: https://github.com/anikethsaha/cssnano-nightly
- Issues: https://github.com/cssnano/cssnano/issues
- npm.io page: https://npm.io/package/postcss-discard-unused-nightly

## Dependencies (3)

- [uniqs](https://npm.io/package/uniqs.md) ^2.0.0
- [postcss](https://npm.io/package/postcss.md) ^7.0.16
- [postcss-selector-parser](https://npm.io/package/postcss-selector-parser.md) ^3.1.1

## Alternatives

- [style-dictionary](https://npm.io/package/style-dictionary.md) — 2.0M weekly downloads
- [postcss-merge-idents](https://npm.io/package/postcss-merge-idents.md) — 1.7M weekly downloads
- [@fontsource/noto-sans](https://npm.io/package/@fontsource/noto-sans.md) — 93.0K weekly downloads
- [uglifycss](https://npm.io/package/uglifycss.md) — 71.6K weekly downloads
- [mat4-interpolate](https://npm.io/package/mat4-interpolate.md) — 23.3K weekly downloads

## Recent versions

- 0.8.4 (latest) — 2020-08-04
- 0.8.1 — 2020-08-01
- 0.7.31 — 2020-07-31
- 0.7.25 — 2020-07-25
- 0.7.24 — 2020-07-24
- 0.7.8 — 2020-07-08
- 0.6.30 — 2020-06-30
- 0.6.27 — 2020-06-27
- 0.6.26 — 2020-06-26

## README

### This is an un-official nightly release of cssnano's postcss-discard-unused 

In this, the package is named as postcss-discard-unused-nightly

In from this docs, you need to replace every 

postcss-discard-unused --> postcss-discard-unused-nightly



***
Original Docs below
***

# [postcss][postcss]-discard-unused

> Discard unused counter styles, keyframes and fonts.


## Install

With [npm](https://npmjs.org/package/postcss-discard-unused) do:

```
npm install postcss-discard-unused --save
```


## Example

This module will discard unused at rules in your CSS file, if it cannot find
any selectors that make use of them. It works on `@counter-style`, `@keyframes`
and `@font-face`.

### Input

```css
@counter-style custom {
    system: extends decimal;
    suffix: "> "
}

@counter-style custom2 {
    system: extends decimal;
    suffix: "| "
}

a {
    list-style: custom
}
```

### Output

```css
@counter-style custom {
    system: extends decimal;
    suffix: "> "
}

a {
    list-style: custom
}
```

Note that this plugin is not responsible for normalising font families, as it
makes the assumption that you will write your font names consistently, such that
it considers these two declarations differently:

```css
h1 {
    font-family: "Helvetica Neue"
}

h2 {
    font-family: Helvetica Neue
}
```

However, you can mitigate this by including [postcss-minify-font-values][mfv]
*before* this plugin, which will take care of normalising quotes, and
deduplicating. For more examples, see the [tests](src/__tests__/index.js).


## Usage

See the [PostCSS documentation](https://github.com/postcss/postcss#usage) for
examples for your environment.


## API

### discardUnused([options])

#### options

##### fontFace

Type: `boolean`  
Default: `true`

Pass `false` to disable discarding unused font face rules.

##### counterStyle

Type: `boolean`  
Default: `true`

Pass `false` to disable discarding unused counter style rules.

##### keyframes

Type: `boolean`  
Default: `true`

Pass `false` to disable discarding unused keyframe rules.

##### namespace

Type: `boolean`  
Default: `true`

Pass `false` to disable discarding unused namespace rules.


## Usage

See the [PostCSS documentation](https://github.com/postcss/postcss#usage) for
examples for your environment.

## Contributors

See [CONTRIBUTORS.md](https://github.com/cssnano/cssnano/blob/master/CONTRIBUTORS.md).

## License

MIT © [Ben Briggs](http://beneb.info)


[postcss]: https://github.com/postcss/postcss
[mfv]:     https://github.com/trysound/postcss-minify-font-values

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