npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-loader-animate

v1.2.0

Published

92+ beautiful, performant React loading animation components

Readme

react-loader-animate

A collection of 92+ animated loading components built with React, TypeScript, and Tailwind CSS — lightweight, tree-shakable, and fully customizable.

npm version npm downloads React TypeScript Tailwind CSS License: MIT


✨ Features

  • 🎨 92+ loader animations — spin, pulse, wave, orbit, DNA, hourglass, and more
  • 📐 3 built-in sizessm, md, lg
  • 🎭 4 colour variantsprimary, accent, success, warning
  • 🖌️ Full customisationcolor, height, width, animationDuration, strokeWidth, colors[]
  • Accessiblerole="status", aria-label, visible prop for screen-reader-friendly hiding
  • Performance-first — every component wrapped in React.memo, zero runtime dependencies
  • 🌗 Dark mode — CSS custom properties, works with any theming strategy
  • 🌲 Tree-shakable — import only what you use; unused loaders are eliminated at build time
  • 🔧 TypeScript — complete type definitions included

📦 Installation

# npm
npm install react-loader-animate

# pnpm
pnpm add react-loader-animate

# yarn
yarn add react-loader-animate

Peer dependencies: react >= 17, react-dom >= 17


🚀 Quick Start

Option 1 — Pre-built CSS

// main.tsx / _app.tsx
import 'react-loader-animate/dist/index.css';

Option 2 — Tailwind CSS preset (recommended)

// tailwind.config.ts
import loaderPreset from 'react-loader-animate/tailwind.preset';

export default {
  presets: [loaderPreset],
  content: [
    './src/**/*.{ts,tsx}',
    'node_modules/react-loader-animate/dist/**/*.{js,mjs}',
  ],
};

Use a component

import { SpinLoader, DotsLoader, GradientSpinner } from 'react-loader-animate';

export default function App() {
  return (
    <div>
      <SpinLoader />
      <SpinLoader size="lg" variant="accent" />
      <SpinLoader color="#6366f1" animationDuration={0.6} />
    </div>
  );
}

🎛️ Props

All components share a common LoaderProps interface:

| Prop | Type | Default | Description | |---|---|---|---| | size | 'sm' \| 'md' \| 'lg' | 'md' | Preset size | | variant | 'primary' \| 'accent' \| 'success' \| 'warning' | 'primary' | Colour theme token | | color | string | — | Custom CSS colour (overrides variant) | | height | number \| string | — | Custom height in px or CSS string | | width | number \| string | — | Custom width in px or CSS string | | className | string | — | Extra class(es) on the root element | | ariaLabel | string | 'loading' | Accessible label for screen readers | | wrapperStyle | CSSProperties | — | Inline styles on the wrapper | | wrapperClass | string | — | Extra class(es) on the wrapper | | visible | boolean | true | Set to false to hide (returns null) | | strokeWidth | number | 4 | SVG stroke width (SVG-based loaders) | | animationDuration | number | 1 | Animation speed in seconds | | colors | string[] | — | Custom colour array (e.g. ColorRingLoader) |


🧩 Component Catalogue

Basic & Spinner

SpinLoader · DotsLoader · PulseLoader · WaveLoader · GradientSpinner · RingLoader · BarLoader · TypingDotsLoader · SyncLoader · BarsLoader · RotatingLoader

Shapes

SquareLoader · TriangleLoader · DiamondLoader · CrossLoader · HexagonLoader · PentagonLoader · StarLoader · ArrowLoader · ChevronLoader · PyramidLoader · CubeLoader

Motion & Physics

FlipLoader · OrbitLoader · ButterflyLoader · SegmentLoader · SpiralLoader · GridLoader · Grid3x3Loader · BounceBallLoader · ClockLoader · DNALoader · HeartbeatLoader · InfinityLoader · GearLoader · HourglassLoader · RadarLoader · PendulumLoader · AtomLoader

Advanced / Multi-colour

ColorRingLoader · CircularProgressLoader · TailSpinLoader · BallTriangleLoader · HashLoader · MutatingDotsLoader · ThreeDotsFadeLoader

Split & Transform

CornerSquaresLoader · SquareSplitLoader · TriangleSplitLoader · CircleSplitLoader · DiamondSplitLoader · HexagonSplitLoader


💡 Usage Examples

// Custom colour
<SpinLoader color="#f43f5e" size="lg" />

// Custom size override
<RingLoader height={80} width={80} strokeWidth={6} />

// Controlled visibility
<DotsLoader visible={isLoading} />

// Multi-colour ring
<ColorRingLoader colors={['#e15b64', '#f47e60', '#f8b26a', '#abbd81', '#849b87']} />

// Slow down animation
<PulseLoader animationDuration={2} variant="success" />

// Wrapper customisation
<SpinLoader wrapperClass="flex items-center justify-center" wrapperStyle={{ minHeight: 200 }} />

🌗 Dark Mode

The library uses CSS custom properties for colour tokens. Add the following variables to your global CSS:

:root {
  --primary:   262 80% 60%;
  --accent:    25 95% 53%;
  --success:   142 71% 45%;
  --warning:   38 92% 50%;
}

.dark {
  --primary:   262 80% 65%;
  --accent:    25 95% 58%;
  --success:   142 71% 50%;
  --warning:   38 92% 55%;
}

📖 Documentation

Live demo and full API reference: react-loader-animate docs


🤝 Contributing

Contributions, issues, and feature requests are welcome! Please open an issue or submit a pull request on GitHub.


📄 License

MIT © danhnhdeveloper308