• Stars
    star
    251
  • Rank 161,862 (Top 4 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created over 5 years ago
  • Updated almost 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Awesome spinners for React 👋 ⚛ Built with styled-components 💅

react-awesome-spinners

NPM version Build Status Coverage Status minified-size js-standard-style MIT License

Loading spinners for React, built with styled-components.

Demo

react-awesome-spinners

Installation

npm

npm i react-awesome-spinners

yarn

yarn add react-awesome-spinners

Usage

  1. Import any spinner
import { Ring } from 'react-awesome-spinners'
  1. Use it as usual
import React, { useState } from "react";
import ReactDOM from "react-dom";
import { Ring } from "react-awesome-spinners";

const App = () => {
  const [loading, setLoading] = useState(true)
    
  return (
      loading && <Ring />
  );
}

ReactDOM.render(<App />, document.getElementById("root"));

Default Props

Common default props for all loaders:

size: 64,
color: '#00bfff',
sizeUnit: 'px'

Peer dependencies

  • React (of course ⛵️)
  • styled-components

Examples