React js text scroll plug-in, push a new data, scroll once.
yarn add react-scroll-log-text // or npm install --save react-scroll-log-text
import React, { Component } from 'react'
import MyComponent from 'react-scroll-log-text'
import 'react-scroll-log-text/dist/index.css'
class Example extends Component {
render() {
return <MyComponent />
}
}
name | desc | type | default |
---|---|---|---|
data |
data | Array or Object | [] |
animateSpeed |
Animation scroll transition time, unit: second | Number | 1 |
length |
Data larger than 'length' starts to scroll | Number | 5 |
liStyle |
The sytle of the li label (the pixel must be added with the unit px) | Object | |
childrenFc |
Custom rendering item components, such as when data is multiple fields | function |
MIT © rfw