# styled-rules

> Presets style rules, theme based, highly customizable style props

Latest version **0.3.1** (published 2018-08-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install styled-rules
pnpm add styled-rules
yarn add styled-rules
bun add styled-rules
```

## 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.3.1 |
| Published | 2018-08-10 |
| First published | 2018-03-17 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=8 |
| Dependencies | 1 |
| Unpacked size | 34.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Bruno Bertolini |
| Maintainers | brunobertolini |
| Keywords | react, css, css-in-js, styled-components, props, theme |

## Links

- npm: https://www.npmjs.com/package/styled-rules
- Repository: https://github.com/brunobertolini/styled-rules
- Homepage: https://github.com/brunobertolini/styled-rules#readme
- Issues: https://github.com/brunobertolini/styled-rules/issues
- npm.io page: https://npm.io/package/styled-rules

## Dependencies (1)

- [prop-types](https://npm.io/package/prop-types.md) ^15.6.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.3.1 (latest) — 2018-08-10
- 0.3.0 — 2018-08-10
- 0.2.1 — 2018-08-09
- 0.2.0 — 2018-08-09
- 0.1.0 — 2018-04-10
- 0.0.0 — 2018-03-17

## README

# styled-rules [![Build Status](https://travis-ci.org/brunobertolini/styled-rules.svg?branch=master)](https://travis-ci.org/brunobertolini/styled-rules) [![codecov](https://codecov.io/gh/brunobertolini/styled-rules/badge.svg?branch=master)](https://codecov.io/gh/brunobertolini/styled-rules?branch=master)

> Preset style rules, theme based, highly customizable style props

## Install

```
yarn add styled-rules
```

## Basic usage

```js
import React from "react";
import PropTypes from "prop-types";
import styled from "styled-components";
import styledBy from "styled-by";
import { flexbox } from "styled-rules";

const propTypes = {
	...flexbox.propTypes
};

const defaultProps = {
	...flexbox.defaultProps
};

const Wrapper = props => <div {...props}>Styled Rules!</div>;

Wrapper.propTypes = propTypes;
Wrapper.defaultProps = defaultProps;

export default styled(Wrapper)`
	${styledBy(flexbox.rules)};
`;
```

## License

MIT © [Bruno Bertolini](http://brunobertolini.com)

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