1.0.6 • Published 3 years ago

react-typewriting-animation v1.0.6

Weekly downloads
6
License
ISC
Repository
github
Last release
3 years ago

react-typewriting-animation

Source code at https://github.com/weianofsteel/react-typewriting-animation

Installation

npm install --save react-typewriting-animation

or

yarn add react-typewriting-animation

Usage

import React from 'react';
import Typewriter from 'react-typewriting-animation';

const Demo = () => {
    return(
        <React.Fragment>
            <Typewriter
                rotateSpeed={1500}
                typeSpeed={150}
                fontSize={'24px'}
                fontFamily={'Roboto'}
                color={'#6f6f6f'}
                heading={'Typewriter'}
                dataText={['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday']}
            />  
        </React.Fragment>
    )
}

export default Demo;

Props

NameTypeDefaultDescription
dataTextarray It's an array, put the sentences as elements.
Each element should be string
headingstring''Title of this animation.
fontFamilystringautoDefines font family for typewriting contents.
fontSizestring'20px'Defines font size for typewriting contents.
colorstring'black'Defines color for typewriting contents.
rotateSpeednumber500How long typewriting animation show a full
element.
typeSpeednumber150Speed of typewriting animation.