Skip to content

Instantly share code, notes, and snippets.

@fabiobiondi
Last active August 29, 2015 14:07
Show Gist options
  • Save fabiobiondi/51d8cfe047154ceedfc2 to your computer and use it in GitHub Desktop.
Save fabiobiondi/51d8cfe047154ceedfc2 to your computer and use it in GitHub Desktop.
D3 SVG displayy
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<script src="http://d3js.org/d3.v3.min.js"></script>
</head>
<body>
<script type="text/javascript">
var svg = d3.select('body').append('svg')
.attr('width', '300px')
.attr('height', '200px')
svg.append('circle')
.attr('cx', '60')
.attr('cy', '60')
.attr('r', '60')
.attr('fill', 'red')
.attr('opacity', '0.4');
</script>
</body>
</html>
#pippo {
lll
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment