let link = document.createElement('a'); link.style.display = 'none'; link.href = url; document.body.appendChild(link); link.click();