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 🙏

© 2024 – Pkg Stats / Ryan Hefner

particles-blob

v1.0.3

Published

`ParticlesBlob` is a customizable particle animation component for React. You can use it to create dynamic, visually appealing particle effects in your applications with minimal effort.

Downloads

9

Readme

ParticlesBlob

ParticlesBlob is a customizable particle animation component for React. You can use it to create dynamic, visually appealing particle effects in your applications with minimal effort.

Features

  • Customize particle size, amount, and animation duration
  • Apply border radius, blur, and blend mode effects
  • Use gradient or solid colors as background
  • Lightweight and easy to integrate into any React project

Installation

To install the package, use npm or yarn:

NPM

npm install particles-blob

Yarn

yarn add particles-blob

Usage

Once installed, you can import and use the ParticlesBlob component in your project like this:

import React from 'react';
import ParticlesBlob from 'particles-blob';

const App: React.FC = () => {
  return (
    <div>
      <ParticlesBlob
        particleSize={200}
        animationDuration={5}
        amount={50}
        borderRadius={100}
        blur={0}
        blendMode="normal"
        backgroundColors="radial-gradient(63.62% 69.52% at 100% 0%, rgba(247, 214, 98, 0.8) 0%, rgba(247, 214, 98, 0.17) 52.08%, rgba(247, 214, 98, 0) 100%)"
      />
    </div>
  );
};

export default App;

Props

Here’s a list of all the props that can be passed to the ParticlesBlob component:

| Prop | Type | Description | Default Value | |---------------------|-----------|------------------------------------------------------------|---------------| | particleSize | number | Defines the size of particles. | 100 | | animationDuration | number | Sets the animation duration of particles (in seconds). | 5 | | amount | number | Specifies the number of particles. | 30 | | borderRadius | number | Controls the border radius of the particles. | 50 | | blur | number | Applies a blur effect to the particles. | 0 | | blendMode | string | Specifies the background blend mode for the particles. | "normal" | | backgroundColors | string | Sets the background color or gradient for the particles. | "" |

Example

import React from 'react';
import ParticlesBlob from 'particles-blob';

const Example = () => (
  <div>
    <ParticlesBlob
      particleSize={150}
      animationDuration={4}
      amount={40}
      borderRadius={75}
      blur={10}
      blendMode="multiply"
      backgroundColors="radial-gradient(circle, rgba(63,94,251,1) 0%, rgba(252,70,107,1) 100%)"
    />
  </div>
);

export default Example;

Customization

You can pass any valid CSS background value to the backgroundColors prop, including gradients, solid colors, or multiple backgrounds. Combine the effects of blur, borderRadius, and blendMode to create unique visual styles.

Blend Modes

The blendMode prop allows you to choose different background blend modes, such as:

  • normal
  • multiply
  • screen
  • overlay
  • darken
  • lighten
  • color-dodge
  • color-burn

Contributing

If you’d like to contribute to the development of ParticlesBlob, please feel free to submit a pull request or open an issue.

License

This project is licensed under the MIT License. See the LICENSE file for more details.