A pseudo-"filter" used to filter <svg>
elements with more customization and (supposedly) better performance than using SVG's <filter>
, using elements traversal and modification approach to filter the SVG elements individually.
- Grayscaling filter
- Colorizing (uniformize colors of each elements)
- Option to omit colors (color)
<SVGFilter>
<svg...> // Your SVG files here
</SVGFilter>
Supported props :
grayscale
: Applying the grayscale filter to SVGcolorize
: Applying the color uniformization filter to SVGcolorProps
: Properties to be used ifcolorize
filter activatedcolor: string
: Color to be applied incolorize
filteromittedColors: string[]
: Colors to be excluded from filtering when an element's color matched one of the color in this array
- Publish to NPM + Yarn
- More filters (sepia, monochrome, etc.)
- Documentations
- Ability to embed external files