# react-x-ray

> CSS layout debugger component

Latest version **1.0.0-4** (published 2017-12-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-x-ray
pnpm add react-x-ray
yarn add react-x-ray
bun add react-x-ray
```

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0-4 |
| Published | 2017-12-13 |
| First published | 2017-05-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 4 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Brent Jackson |
| Maintainers | jxnblk |
| Keywords | react, react-component, ui, development, style, css |

## Links

- npm: https://www.npmjs.com/package/react-x-ray
- npm.io page: https://npm.io/package/react-x-ray

## Dependencies (4)

- [chroma-js](https://npm.io/package/chroma-js.md) ^1.3.4
- [nano-style](https://npm.io/package/nano-style.md) ^1.0.0-20
- [prop-types](https://npm.io/package/prop-types.md) ^15.6.0
- [object-assign](https://npm.io/package/object-assign.md) ^4.1.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

- 1.0.0-4 (latest) — 2017-12-13
- 1.0.0-3 — 2017-09-23
- 1.0.0-2 — 2017-06-11
- 1.0.0-1 — 2017-05-30
- 1.0.0-0 — 2017-05-30

## README

# React X-Ray

React CSS Layout Debugger

![demo](docs/x-ray.gif)

```sh
npm i react-x-ray
```

Demo: <http://jxnblk.com/react-x-ray>


## Usage

```jsx
import React from 'react'
import XRay from 'react-x-ray'

const App = props => (
  <XRay>
    <div style={{ padding: 32 }}>
      <h1>Look at me!</h1>
    </div>
  </XRay>
)
```

## Props

- `grid` (number or boolean) pixel dimensions of background grid
- `outline` (boolean) show element outlines
- `center` (boolean) center the background grid
- `color` (string) base color for grid and outlines
- `backgroundColor` (string) background color of XRay component

Inspired by [Tachyons X-RAY](http://tachyons.io/xray/)

MIT License

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