svg-filter-animation

1.1.1 • Public • Published

svg-filter-animation

Plays given SVG-filter animations created with SVG-Pro

See https://github.com/JJ995/svg-pro

Installation

Install package to your project:

npm install svg-filter-animation

Include package:

import SVGFilterAnimation from 'svg-filter-animation';

Paste your generated filter code on your site and link the filter to an element via CSS. e.g.: style="filter: url(#svgFilter)" Make sure you have set an unique ID for the filter!

Place the downloaded keyframes .json-file somewhere accessible on your server.

Trigger the animation whenever you want by calling:

SVGFilterAnimation.SVGFilterAnimation([PATH_TO_KEYFRAMES]);

e.g.:

SVGFilterAnimation.SVGFilterAnimation('/keyframes.json');

Package Sidebar

Install

npm i svg-filter-animation

Weekly Downloads

4

Version

1.1.1

License

ISC

Unpacked Size

15.6 kB

Total Files

4

Last publish

Collaborators

  • jj_npm