I have implemented file download in the following way
var link = document.createElement("a"); link.download = name; link.href = uri; document.body.a