返回首頁 

Greasy Fork is available in English.

Inline SVG Replacer

Replace all img tags with src as an SVG file into inline SVG tags


Installer ce script?
Auteur
mkpoli
Installations quotidiennes
0
Installations (total)
5
Notes
000
Version
0.1.1
Créé
12/01/2024
Mis à jour
12/01/2024
Taille
1,63 ko
Licence
CC0
S'applique à
Tous les sites

This a script that replaces all <img> tags that render svg images to inlined <svg> tags. The point of this is to allow advanced svg features like currentColor, so that we can modify the style of a website to change the color in svg, or do furthor modifications to the <svg> element. A common usage is for Dark Readers, where they cannot change color of a svg for something such as math equations, but by this script, the dark reader then can correctly apply the inverted color.