D3
OG
Old school D3 from simpler times
All examples
By author
By category
About
micahstubbs
Full window
Github gist
building blocks svg flag
datasana #1
<!DOCTYPE html> <head> <meta charset="utf-8"> <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js"></script> </head> <style> body { position: fixed; top: 0; bottom: 0; left: 0; right: 0; } </style> <body style="margin0"> <svg width=100% height=100%> <circle r=50 cx=280 cy=60></circle> <rect x=2.72 y=2.8 width=100 height= 200></rect> <path d="M125,101L222,194L225,101Z" fill="none" stroke="steelblue" stroke-width="10"> </path> </svg> <script> d3.select("circle") .style("fill","steelblue"); d3.select("rect") //.attr("transform", "rotate(-90)") .style("fill", "gray"); </script> </body>
https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js