Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

if workbox precache fails then there is not a way to identify that #668

Open
harshagarwal-mono opened this issue Feb 21, 2024 · 6 comments

Comments

@harshagarwal-mono
Copy link

if workbox fails to load a single precache files. I am not able to add a handler for that

@userquin
Copy link
Member

The failing resource url should be shown in the console, you must fix the error: the problem is when the sw is installing, sw will download all resources in the sw precache manifest

@harshagarwal-mono
Copy link
Author

I know that part. but my problem is sometime it is possible that due to temporary glitches or say due to network condition a file is unable to be cached. At that time i want to inform user about failure. I am sharing PWA embedded in desktop app. That is really criticla for me otherwise user will see infinite splash screen untill he restarts the app

@userquin
Copy link
Member

If you're using any pwa virtual module, the onRegisterError callback should be called

@harshagarwal-mono
Copy link
Author

onRegisterError is called if registration is failed but here precache is failed but registration is successful

@userquin
Copy link
Member

Uhmm, so the sw is green with the red circle error in dev tools. I'll check workbox options...

@harshagarwal-mono
Copy link
Author

Any update here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants