react-scroll-log-text
v1.0.0
Published
This is a React log text scrolling component.
Downloads
1
Readme
react-scroll-log-text
React js text scroll plug-in, push a new data, scroll once.
Install
yarn add react-scroll-log-text // or npm install --save react-scroll-log-text
Usage
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 />
}
}
Props
|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 | |
License
MIT © rfw