export function render()

in client/src/views/widget.js [19:35]


export function render(body) {

    var buffer = body;

    var imageStr = arrayBufferToBase64(buffer);

    let temporary = document.createElement('div');
    temporary.innerHTML = html;
   
    body = document.getElementsByTagName('body')[0];
    while (temporary.children.length > 0) {
        elements.push(temporary.children[0]);
        temporary.children[0].setAttribute('src', 'data:image/png;base64,' + imageStr);
        body.appendChild(temporary.children[0]);
    }
  
}