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

Add handleFetch back in for development #2272

Closed
bnikom opened this issue Nov 6, 2019 · 1 comment
Closed

Add handleFetch back in for development #2272

bnikom opened this issue Nov 6, 2019 · 1 comment
Labels
Discuss An open question, where input from the community would be appreciated. workbox-core

Comments

@bnikom
Copy link

bnikom commented Nov 6, 2019

Library Affected:
workbox-build, workbox-sw

Is it possible to add the handleFetch option back into WorkboxSW and workbox-build? It's a convenient part of the build chain that helps separate development and production builds. I understand there's a feature in the Dev Tools application tab that easily mimics this option, but having it built into the build process is a fail-safe if a developer forgets, is unused to using the Dev Tools feature, or just doesn't totally understand how service workers work.

I'm open to discussing it, but in the previous thread (where this feature was removed)
#1002
it was mentioned that the discussion can be re-opened if people ask for it.

@jeffposnick jeffposnick added Discuss An open question, where input from the community would be appreciated. workbox-core labels Nov 21, 2019
@jeffposnick
Copy link
Contributor

At this point, especially as we move away from workbox-sw for our "recommended" developer experience, I don't think we're going to add this back.

It can, to some extent, be replicated by using process.env.NODE_ENV inside of if() statements prior to bundling your service worker.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Discuss An open question, where input from the community would be appreciated. workbox-core
Projects
None yet
Development

No branches or pull requests

2 participants