fade-svg

0.1.1 • Public • Published

fade-svg

Function to randomly fade elements from a given selector of an svg

Usage

import fadeSVG from 'fade-svg'

const mySvg = document.querySelector('svg')

fadeSVG({ svg: svg, selector: 'polygon' }) // will randomly fade-in all polygons inside the svg

Note: your svg MUST be inline. You can't have a img tag with an svg source.

Just npm install fade-svg and then you can import it in your code.

Readme

Keywords

Package Sidebar

Install

npm i fade-svg

Weekly Downloads

11

Version

0.1.1

License

SEE LICENSE IN LICENSE.md

Unpacked Size

77.1 kB

Total Files

11

Last publish

Collaborators

  • graciano