Using the label
A Pen by A Non Ymous on CodePen.
Using the label
A Pen by A Non Ymous on CodePen.
Object.defineProperty(SVGElement.prototype, 'innerSVG', { | |
get: function() { | |
var $node, $temp; | |
$temp = document.createElement('div'); | |
$node = this.cloneNode(true); | |
$temp.appendChild($node); | |
return $temp.innerHTML; | |
}, | |
set: function(markup) { | |
var $element, $temp, _i, _len, _ref, _results; |