# react-responsivebr

> which adapts to the window width

Latest version **1.0.0** (published 2018-08-05) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

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

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2018-08-05 |
| First published | 2017-10-24 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 8.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Juliette Pretot |
| Maintainers | juliettepretot |

## Links

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

## Dependencies (1)

- [react](https://npm.io/package/react.md) ^15.5.4

## Recent versions

- 1.0.0 (latest) — 2018-08-05
- 0.1.0 — 2018-08-05
- 0.0.4 — 2018-08-05
- 0.0.3 — 2017-11-23
- 0.0.2 — 2017-10-24

## README

# react-responsivebr

**ResponsiveBr** is a `<br>` tag which is adapts to the viewport width. It renders a line break if you want to and a white space otherwise. You can specify a min width, a maximum width or both.

By default each <ResponsiveBr/> uses its own eventListeners to record viewport changes. Alternatively one can also pass `windowWidth` as a prop.

1.8kb gzipped.

## Basic usage

Import using:

```
import ResponsiveBr from 'react-ResponsiveBr';
```

Then use it like this:

```
The following linebreak<ResponsiveBr maxWidth="800" />renders only if the browser is less than 800px wide.

The following linebreak<ResponsiveBr minWidth="500" />renders only if the browser is more than 500px wide.

The following linebreak<ResponsiveBr minWidth="400" maxWidth="600" />renders only if the browser is between 400px and 600px wide.
```

[![Edit Demo responsiveBr](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/z2nq570o2p)

## Installing

```
npm i react-ResponsiveBr
```

or

```
yarn add react-ResponsiveBr
```

## License

MIT-licensed.

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