D3
OG
Old school D3 from simpler times
All examples
By author
By category
About
HarryStevens
Full window
Github gist
External SVG In Multipile Nodes
<!DOCTYPE html> <meta charset="utf-8"> <body> <div class="container"></div> <div class="container"></div> <div class="container"></div> <div class="container"></div> <div class="container"></div> <script src="https://d3js.org/d3.v4.js"></script> <script> d3.xml("rect01.svg").mimeType("image/svg+xml").get(function(error, xml) { if (error) throw error; var el = xml.documentElement; document.querySelectorAll(".container").forEach((container, container_index) => { container.appendChild(el.cloneNode(true)); }); }); </script> </body>
https://d3js.org/d3.v4.js