diegomura / react-pdf

📄 Create PDF files using React
https://react-pdf.org
MIT License
14.94k stars 1.18k forks source link

Nested SVG elements #943

Open cmnstmntmn opened 4 years ago

cmnstmntmn commented 4 years ago

There's the case when a Svg element should be wrapped into another

<svg>
    <svg width="80%"><text>Child</text></svg>
    <text>Parent</text>
</svg>

since the group <g></g> is not supporting width, there's no easy way to change position/size of a child element.

here's an example

HelgiBergmann commented 1 year ago

@diegomura looking for this too, right now I can render svg inside svg but positioning is left much to be desired

Manitej66 commented 1 year ago

@HelgiBergmann how did you able to render svg inside svg? I was getting r is not defined error