jimmywarting / StreamSaver.js

StreamSaver writes stream to the filesystem directly asynchronous
https://jimmywarting.github.io/StreamSaver.js/example.html
MIT License
3.97k stars 413 forks source link

Downloads don't work on the first attempt #235

Closed JamesCorrigan closed 3 years ago

JamesCorrigan commented 3 years ago

I have the service worker hosted in a react app and the download function is working, but it doesn't work on the first attempt because the service worker is not registered yet. I need to register the service worker before my download function is called, but so far I have been unable to do that. Is there a way to ping streamsaver with an empty message so that the serviceworker gets registered before downloads happen?

jimmywarting commented 3 years ago

dupl #233