Skip to content

Tiny React Component helps to delay component mounting time.

Notifications You must be signed in to change notification settings

neroze/lazy-load-component

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Delay component load

Just delays component rendering time with counter
Alt text Alt text Alt text

Installation

$ npm i delay-component-load
OR
$ yarn add delay-component-load

Usage

	const SET_TIME_INTERVAL = 10;
	.
	.
	.
	<Lazy
		timeInterval={this.state.timeInterval}
		label={`You can resend in %timer% seconds`}
	>
		<span
			className='textbutton textbutton--small'
			onClick={(e) => {
				// this.handleInvite(e, false, false)
				this.setState({
					timeInterval: SET_TIME_INTERVAL
				})
			}}
		>
			Resend
		</span>
	</Lazy>

About

Tiny React Component helps to delay component mounting time.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published