# postcss-flexbugs-fixes

> PostCSS plugin This project tries to fix all of flexbug's issues

Latest version **5.0.2** (published 2020-11-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install postcss-flexbugs-fixes
pnpm add postcss-flexbugs-fixes
yarn add postcss-flexbugs-fixes
bun add postcss-flexbugs-fixes
```

## Health

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

Positive: has types package; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 5.0.2 |
| Published | 2020-11-20 |
| First published | 2015-06-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/postcss-flexbugs-fixes) |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 8.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 741 |
| Author | Luis Rudge |
| Maintainers | luisrudge |
| Keywords | postcss, css, postcss-plugin, flexbugs, flexbox, flex |

## Links

- npm: https://www.npmjs.com/package/postcss-flexbugs-fixes
- Repository: https://github.com/luisrudge/postcss-flexbugs-fixes
- Homepage: https://github.com/luisrudge/postcss-flexbugs-fixes#readme
- Issues: https://github.com/luisrudge/postcss-flexbugs-fixes/issues
- npm.io page: https://npm.io/package/postcss-flexbugs-fixes

## 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

- 5.0.2 (latest) — 2020-11-20
- 5.0.1 — 2020-11-08
- 5.0.0 — 2020-10-31
- 4.2.1 — 2020-04-27
- 4.2.0 — 2020-02-04
- 4.1.0 — 2018-07-30
- 4.0.0 — 2018-07-18
- 3.3.1 — 2018-04-28
- 3.3.0 — 2018-01-18
- 3.2.0 — 2017-07-31
- 3.1.0 — 2017-07-31
- 3.0.0 — 2017-05-10
- 2.1.1 — 2017-04-12
- 2.1.0 — 2016-12-06
- 2.0.0 — 2015-10-16
- … 7 more at https://npm.io/package/postcss-flexbugs-fixes/versions

## README

# PostCSS Flexbugs Fixes [![Build Status][ci-img]][ci]
[PostCSS] plugin This project tries to fix all of [flexbug's](https://github.com/philipwalton/flexbugs) issues.

## bug [4](https://github.com/philipwalton/flexbugs/blob/master/README.md#4-flex-shorthand-declarations-with-unitless-flex-basis-values-are-ignored)
### Input

```css
.foo { flex: 1; }
.bar { flex: 1 1; }
.foz { flex: 1 1 0; }
.baz { flex: 1 1 0px; }
```

### Output

```css
.foo { flex: 1 1; }
.bar { flex: 1 1; }
.foz { flex: 1 1; }
.baz { flex: 1 1; }
```

## bug [6](https://github.com/philipwalton/flexbugs/blob/master/README.md#6-the-default-flex-value-has-changed)
### Input

```css
.foo { flex: 1; }
```

### Output

```css
.foo { flex: 1 1 0%; }
```

> This only fixes css classes that have the `flex` property set. To fix elements that are contained inside a flexbox container, use this global rule:
```css
* {
    flex-shrink: 1;
}
```

## bug [8.1.a](https://github.com/philipwalton/flexbugs/blob/master/README.md#8-flex-basis-doesnt-support-calc)
### Input

```css
.foo { flex: 1 0 calc(1vw - 1px); }
```

### Output

```css
.foo {
  flex-grow: 1;
  flex-shrink: 0;
  flex-basis: calc(1vw - 1px);
}
```

## Usage

```js
postcss([require('postcss-flexbugs-fixes')]);
```

You can also disable bugs individually, possible keys `bug4`, `bug6` and `bug8a`.
```js
var plugin = require('postcss-flexbugs-fixes');
postcss([plugin({ bug6: false })]);
```

See [PostCSS] docs for examples for your environment.

[postcss]: https://github.com/postcss/postcss
[ci-img]: https://travis-ci.org/luisrudge/postcss-flexbugs-fixes.svg
[ci]: https://travis-ci.org/luisrudge/postcss-flexbugs-fixes

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