0.2.0 • Published 2 years ago
react-countingstar v0.2.0
React-Countingstar
a component for slot count animation
You can install it at npm, yarn
npm install react-countingstar
yarn add react-countingstar
Basic usage
import { CountingStar } from 'react-countingstar';
function example () {
return {
<CountingStar
cntNum={20040706}
fontSize="4rem"
time={6}
/>
}
}
* Be careful because the style can be destroyed by the discharge or overlapping css.
Props
cntNum
A number to count
- type : number
fontSize
CountingStar text font-size
- type : number | cssFontUnitType
if it is number, it'll be added "px"
time
CountingStar Animation Duration
- type : number