Socket
Socket
Sign inDemoInstall

anim-gradient

Package Overview
Dependencies
0
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    anim-gradient

Tilted gradient effect


Version published
Weekly downloads
18
increased by50%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

Animated gradient

Install

npm:

npm install anim-gradient

How to use

  • Setup this on your main.css file
    #gradient-canvas {
        --gradient-color-1: #6ec3f4;
        --gradient-color-2: #3a3aff;
        --gradient-color-3: #ff61ab;
        --gradient-color-4: #E63946;
    }
  • Import Gradient class, create new instance and run initGradient

  import { Gradient } from 'anim-gradient';

  const gradient = new Gradient()
  gradient.initGradient('#gradient-canvas');

Inspiration

Based on the tilted gradient effect on Stripe's website. Functionality found in Kevin Hufnagl website.

  • Kevin Hufnagl — Learn how to create the tilted gradient effect on Stripe's new website.
  • Stripe — Stripe's website

License

MIT © Federico Biondi

FAQs

Last updated on 25 Nov 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc