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

@devil7softwares/react-drifter-stars

v1.0.6

Published

React version of Drifter Stars by Cory Hughart

Downloads

7

Readme

React Drifter Stars build npm license min minzip

Drifter Stars by @cr0ybot ported to React with Typescript support

Demo

View Demos @ Storybook

Quick Start

  1. Install package from NPM npm install @devil7softwares/react-drifter-stars
  2. Import drifter stars in your component import DrifterStars from '@devil7softwares/react-drifter-stars'
  3. Add component to your JSX/TSX <DrifterStars />
  4. Import default stylesheet from package for default background. Or use your own css. import '@devil7softwares/react-drifter-stars/dist/styles.css'

Note: The component is transparent by default and takes full width and height of window. And can be used with your existing background.

Options

NOTE: All of the options below are optional.

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | color | string | Color of particles, flare & lines. | | renderMesh | boolean | Specifies whether mesh should be rendered. | | blurSize | number | Size of blur for overall canvas. | | particle | IParticleOptions | Particle related options. | | flare | IFlareOptions | Particle flare options. | | glare | IGlareOptions | Glare related options. | | links | ILinkOptions | Link generation options. | | motion | IMotionOptions | Motion/movement options. |

IParticleOptions

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | render | boolean | Specifies whether particles should be rendered. | | count | number | Count of the particles to generate.\nNOTE: Particles will be generated even if its not going to be rendered) | | sizeBase | number | Base size for particles. Size of particle will be calculated as "Z-Axis x Multiplier + Base". | | sizeMultiplier | number | Multiplier for particle size calculation. Size of particle will be calculated as "Z-Axis x Multiplier + Base". | | flickerSmoothing | number | Amount of smoothing to apply on flickering. Higher Value = Smoother Flicker. |

IFlareOptions

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | render | boolean | Specifies whether flares should be rendered. | | count | number | Count of the flares to render. | | sizeBase | number | Base size for flare. Size of flare will be calculated as "Z-Axis x Multiplier + Base". | | sizeMultiplier | number | Multiplier for flare size calculation. Size of flare will be calculated as "Z-Axis x Multiplier + Base". |

IGlareOptions

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | render | boolean | Specifies whether particle glare should be rendered. | | angle | number | Angle for glare to generate. | | opacityMultiplier | number | Glare opacity multiplier. |

ILinkOptions

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | render | boolean | Specifies whether links should be rendered. | | lineWidth | number | Width of link line to generate. | | opacity | number | Opactity for link line. A number between 0 & 1. | | chance | number | Probability for a new line to appear per frame. Higher Value = Smaller Chance. | | fade | number | Number of frames for link to fade-out. | | speed | number | Distance a link travels in 1 frame. | | minLength | number | Minimum number of particles to link when a new line is generated. | | maxLength | number | Maximum number of particles to link when a new line is generated. |

IMotionOptions

| Prop | Type | Description | |-------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------| | enabled | boolean | Enables/disables moving animation of particles. | | ratio | number | Amount of motion to be generated. Default is 0.05.Used to generate motion based on mouse movement/device orientation changes. | | randomMotion | boolean | Enables random motions even without user interation. | | noiseLength | number | Length of noice for random motion. | | noiseStrength | number | Strength of noice for random motion. |

Credits

  • Cory Hughart (@cr0ybot) - For original Drifter Stars animation.
  • Steve Courtney - For Celsius GS's Drifter poster art