npm stats
  • Search
  • About
  • Repo
  • Sponsor
  • more
    • Search
    • About
    • Repo
    • Sponsor

Made by Antonio Ramirez

react-level-value

1.0.0

@juliangruber

npmHomeRepoSnykSocket
Downloads:69
$ npm install react-level-value
DailyWeeklyMonthlyYearly

react-level-value

Live updating leveldb value component for react!

Example

import React from 'react'
import level from 'level'
import { Value } from 'react-level-value'

const db = level('/tmp/react-level-value')

class Example extends React.Component {
  render () {
    return (
      <div>
        Live value: <Value db={db} levelKey="key" />
      </div>
    )
  }
}

Now the <Value /> component will always reflect the value you have stored in your database at key.

Find a full example in /example:

$ npm install
$ npm run rebuild
$ npm start

screenshot

Installation

$ npm install react-level-value

API

<Value db levelKey />

License

MIT