fakiolinho / react-loading

React component for loading animations
https://codesandbox.io/s/mqx0ql55qp
808 stars 111 forks source link
loading-animations preloader react-loading reactjs

react-loading

Build Status Coverage Status

Easy to use loading animations for React projects. Uses SVG animations from Brent Jackson's loading project.

Installation

npm i react-loading

or

yarn add react-loading

Demo

Check here

Loading Types

Examples

import React from 'react';
import ReactLoading from 'react-loading';

const Example = ({ type, color }) => (
    <ReactLoading type={type} color={color} height={667} width={375} />
);

export default Example;
import React from 'react';
import ReactLoading from 'react-loading';

const Example = ({ type, color }) => (
    <ReactLoading type={type} color={color} height={'20%'} width={'20%'} />
);

export default Example;

Props

Name Type Default Value
type String balls
color String #ffffff
delay Number 0 (msecs)
height Number or String 64 (px)
width Number or String 64 (px)
className String ''

License

MIT