I have an API that returns me a PDF file.
I want to make angular hitting this route and forcing the download of the PDF file.
Today I do this:
var blob = new Blob([arquivo], {type: "application/pdf"});
saveAs(blob, 'arquivo.pdf');
The download works, but the pdf file is blank. If I hit the route manually, the file comes complete.