Skip to content

Instantly share code, notes, and snippets.

@sedouard
Created September 17, 2016 00:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sedouard/b2a6244597f47d2d51f5dd6730881fb3 to your computer and use it in GitHub Desktop.
Save sedouard/b2a6244597f47d2d51f5dd6730881fb3 to your computer and use it in GitHub Desktop.
Canvas.js ToBlob
canvas.toBlob(function(blob) {
var fs = require('fs'),
out = fs.createWriteStream(__dirname + '/chart.png');
out.write(jsdom.blobToBuffer(blob));
}, "image/png");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment