3 ms·
Or, in Chrome, use the Console.download() snippet: https://bgrins.github.io/devtools-snippets/#console-save https://bgrins.github.io/devtools-snippets/#console-
by thadk 10y ago
Or, in Chrome, use the Console.download() snippet: https://bgrins.github.io/devtools-snippets/#console-save https://bgrins.github.io/devtools-snippets/#console-save / https://github.com/bgrins/devtools-snippets/tree/master/snippets/console-save https://github.com/bgrins/devtools-snippets/tree/master/snip...
- ontouchstart 10y agoI don't think your solution works for this use case since what he wants is to save the "XML serialized" SVG element instead of a "JSON serialized" JavaScript object. A simple d3.select('svg').node().outerHTML would do the trick. (You can use the same trick as in console-save to generate a download URL though.)