darylldoyle / svg-sanitizer

A PHP SVG/XML Sanitizer
GNU General Public License v2.0
454 stars 67 forks source link

[POC] extract/merge <defs>/<style> #60

Open xerc opened 2 years ago

xerc commented 2 years ago

<style> is not considered within <symbol> when referenced via <use href="svg#id" https://stackoverflow.com/questions/39583880/external-svg-fails-to-apply-internal-css

option/ convert CSS inline via https://github.com/RazrFalcon/svgcleaner before loadXML

darylldoyle commented 2 years ago

Hi @xerc any chance you can expand on what you're trying to solve here a bit please?

xerc commented 2 years ago

combine multible <style/<devs TAGs into single ones ; faster parsing (in the browser) and more structure (for humans)