# @emotion/stylis

> A custom build of Stylis

Latest version **0.8.5** (published 2019-12-22) · MIT license · 0 weekly downloads

## Install

```sh
npm install @emotion/stylis
pnpm add @emotion/stylis
yarn add @emotion/stylis
bun add @emotion/stylis
```

## Health

**Score 45/100 (D)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high maintenance score; popular repo.

Warnings: low downloads; pre 1.0.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 0.8.5 |
| Published | 2019-12-22 |
| First published | 2018-04-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 102.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 18017 |
| Maintainers | emotion-release-bot, mitchellhamilton, tkh44 |

## Links

- npm: https://www.npmjs.com/package/@emotion/stylis
- Repository: https://github.com/emotion-js/emotion/tree/master/packages/stylis
- npm.io page: https://npm.io/package/@emotion/stylis

## Recent versions

- 0.8.5 (latest) — 2019-12-22
- 10.0.0-really-unsafe-please-do-not-use.2 (really-unsafe-please-do-not-use) — 2018-09-28
- 0.8.4 — 2019-06-25
- 0.8.3 — 2018-11-20
- 0.8.2 — 2018-11-12
- 0.8.1 — 2018-11-12
- 0.8.0 — 2018-10-13
- 10.0.0-really-unsafe-please-do-not-use.1 — 2018-09-28
- 10.0.0-really-unsafe-please-do-not-use.0 — 2018-09-27
- 0.7.1 — 2018-09-20
- 0.7.0 — 2018-08-04
- 0.6.12 — 2018-07-15
- 0.6.11 — 2018-07-14
- 0.6.10 — 2018-06-21
- 0.6.9 — 2018-06-16
- … 7 more at https://npm.io/package/@emotion/stylis/versions

## README

# @emotion/stylis

> A custom build of Stylis

`@emotion/stylis` is a version of [Stylis](https://github.com/thysultan/stylis.js) that has been modified slightly to make it smaller. The only Stylis option that can be changed is `prefix`, the rest of the options are already set to the values shown below and cannot be changed. This package also only exports the constructer, so you have to do `new Stylis()` and use the result from that rather than directly calling `Stylis`. The result of that function also cannot be used to create a stylis instance unlike stylis.

```js
type Options = {
  global: false,
  preserve: false,
  keyframe: false,
  semicolon: true,
  cascade: true,
  compress: false,
  prefix: boolean | ((key: string, value: string, context: number) => boolean)
}
```

```jsx
import Stylis from '@emotion/stylis'

const stylis = new Stylis()

stylis('.css-hash', 'display:flex;') // .css-hash{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}
```

## Building this package

To build this package from a newer version of stylis, update the version of stylis that is installed as a devDependency and run `node build.js` in the directory of this package. This will read the source of stylis, transform it slightly, use the [Google Closure Compiler REST API](https://developers.google.com/closure/compiler/docs/gettingstarted_api) to minify it, format it with Prettier and then write it to `src/stylis.min.js`.

# Thanks

Stylis was written by [Sultan Tarimo](https://github.com/thysultan). ❤️

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