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

Service Worker configured to load "prod" styles on "dev" results in 404 #209

Open
FossPrime opened this issue Sep 12, 2016 · 0 comments
Open

Comments

@FossPrime
Copy link
Contributor

FossPrime commented Sep 12, 2016

The 404 errors get annoying in the console. Not quite sure what the benefit of including it service-worker.js is. We could do a debug exclude, or not include it on the hard list, or router around it.

I don't see much benefit to having main.md5hash.css in precache... it's already on the html by the time the sw runs. Or perhaps it would be better to do a quick prod cleanup before running in dev mode.

thoughts?

UPDATE: Sample error:

/service-worker.js:132 Request for http://localhost:8000/styles/main.7af9a142.css?sw-precache=1473853567887 returned a response with status 404, so not attempting to cache it.
@FossPrime FossPrime changed the title sw tries to load production css due to precache sw tries to load prod css in dev due to precache Sep 12, 2016
@FossPrime FossPrime changed the title sw tries to load prod css in dev due to precache Service Worker configured to load "prod" styles on "dev" results in 404 Sep 14, 2016
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

1 participant