For my windows build I am downloading and opening a PDF file like this:
await dio.download(
'https://someurl.com/downloadfile.pdf',
'/save/file/here.pdf',
);
await OpenFile.open('/save/file/here.pdf', type: 'application/pdf');
Is it possible to do that when I publish to the web? I get an error that says:
The download method is not available in the Web environment.
I assume there’s some way to download a file to the browser downloads area. But is it possible to then open it?