html2canvas lets you take screenshots of parts of a page using a JavaScript library.
Here is a sample .chart that contains HTML and SVG:
.chart
Click this button below.
Download screenshot
View source