score:1

If you want to create a pdf file out of your svg code, import your code into Inkscape, and then export it in .pdf format. Then you'll have a standalone pdf file to use.

score:1

You can use SaveSVG open source library I created to save SVG created by D3.js with external stylesheets and imported <use> symbols.

score:3

If you just want to do this by hand (and not programmatically for many SVGs), you can, on the page the SVG is displaying, right-click on it, select "Inspect Element" in Firefox ("Inspect" in Chrome), then on the "Inspector" tab ("Elements" in Chrome), right click on the <svg> element, and select the option to Copy Outer HTML. Then you can paste the copied text into a text editor and save it as an .svg file. I tried that with your example and it opened in Illustrator with the blue line showing the lineData.


Related Query

More Query from same tag