MCPcopy
hub / github.com/davidshimjs/qrcodejs / makeSVG

Function makeSVG

qrcode.js:191–196  ·  view source on GitHub ↗
(tag, attrs)

Source from the content-addressed store, hash-verified

189 this.clear();
190
191 function makeSVG(tag, attrs) {
192 var el = document.createElementNS('http://www.w3.org/2000/svg', tag);
193 for (var k in attrs)
194 if (attrs.hasOwnProperty(k)) el.setAttribute(k, attrs[k]);
195 return el;
196 }
197
198 var svg = makeSVG("svg" , {'viewBox': '0 0 ' + String(nCount) + " " + String(nCount), 'width': '100%', 'height': '100%', 'fill': _htOption.colorLight});
199 svg.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xlink", "http://www.w3.org/1999/xlink");

Callers 1

qrcode.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected