# react-fitclamp

> Fits and clamps typography

Latest version **0.2.1** (published 2019-08-05) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-fitclamp
pnpm add react-fitclamp
yarn add react-fitclamp
bun add react-fitclamp
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.2.1 |
| Published | 2019-08-05 |
| First published | 2019-08-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=8 |
| Dependencies | 0 |
| Unpacked size | 58.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | some1else |
| Maintainers | some1else |

## Links

- npm: https://www.npmjs.com/package/react-fitclamp
- Repository: https://github.com/some1else/react-fitclamp
- Homepage: https://github.com/some1else/react-fitclamp#readme
- Issues: https://github.com/some1else/react-fitclamp/issues
- npm.io page: https://npm.io/package/react-fitclamp

## Recent versions

- 0.2.1 (latest) — 2019-08-05
- 0.2.0 — 2019-08-02
- 0.1.3 — 2019-08-02
- 0.1.2 — 2019-08-02
- 0.1.1 — 2019-08-01
- 0.1.0 — 2019-08-01

## README

# react-fitclamp

> Trims

[![NPM](https://img.shields.io/npm/v/react-fitclamp.svg)](https://www.npmjs.com/package/react-fitclamp) [![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)

## Install

```bash
npm install --save react-fitclamp
```

## Usage

```jsx
import React, { Component } from "react"

import FitClamp from "react-fitclamp"

class Example extends Component {
  render() {
    const containerClass = "card-medium"
    const textSizes = ["size-1", "size-2", "size-3"]
    const text = "Lorem ipsum dolor sit amet"

    return (
      <FitClamp className={containerClass} textClasses={textSizes}>
        {text}
      </FitClamp>
    )
  }
}
```

Make sure the CSS for textClasses contains line-height setting in percentages, integers or pixels. Keywords like "normal" will not work.

## License

MIT © [some1else](https://github.com/some1else)

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