npm.io
0.3.3 • Published 6 years ago

react-dump

Licence
MIT
Version
0.3.3
Deps
3
Size
27 kB
Vulns
0
Weekly
0

react-dump

NPM

A visual debugging component for React. Outputs any variable in an easy to read format based on ColdFusion's CFDUMP tag.

Better than console.log (recurses fully). Less complex than React Developer Tools. Sometimes visualizing a complex object makes it easier to think about. For example, <ReactDump obj={user} /> might yield:

Reactdump example

Inspired in part by Andrew Hewitt's nodedump

Install

[sudo] npm install react-dump --save-dev

Usage

Import to your component:

import {Dump} from 'react-dump';

Include within your component's render() method, passing the object and optional arguments

<Dump obj={user} />

License

MIT

Contributing

Pull requests welcome with accompanying tests

Keywords