1.0.0 • Published 3 years ago
react-ldavis v1.0.0
react-ldavis
React Component for LDAvis
Install
npm install react-ldavis
Usage
import React, { Component } from 'react'
import LDAvis from 'react-ldavis'
import 'react-ldavis/dist/index.css'
class Example extends Component {
render() {
return <LDAvis
data={{...}}
modifyHistory={false}
style={{ textAlign: "center" }}
/>
}
}
API
Name | Type | Default | Description |
---|---|---|---|
data | object | undefined | Visualization object |
modifyHistory | boolean | false | Normally, legacy LDAvis script changes url when you interact with visualization plot. (e.g. when you click on a topic #topic=2&lambda=1&term= appears at the end of the url) When this prop is true , plotting only one plot may not be a problem, but using multiple instances of LDAvis can cause inconsistency. |
style | (style) object | undefined | Styling for <div> container. |
License
MIT © thesseyren
1.0.0
3 years ago