-
Notifications
You must be signed in to change notification settings - Fork 817
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
InjectManifestPlugin with local workbox not gets served over webpack-dev-server #1596
Comments
When using the local Workbox libraries, depending on your configuration, you may need to follow the steps at https://developers.google.com/web/tools/workbox/modules/workbox-sw#using_local_workbox_files_instead_of_cdn inside of your Does tweaking that setting help? |
Thanks for your reply :) My
The InjectManifest plugin transforms it to this
My When the service worker tries to load workbox via this url: https://localhost:8080/workbox-v3.4.1/workbox-sw.js But the browser gets a 404 error for this url. When I build the project (Only using webpack, not the dev server) and upload it to my production server, it loads workbox via this url (I replaced the url with example.com here): https://example.com/workbox-v3.4.1/workbox-sw.js It works fine. I think the whole workbox library gets not served via the |
Same issue here. I think the problem is that Workbox is downloading its files on the real filesystem instead of using Probably this is due to this file, that simply copies Workbox files on the filesystem. By the way, the issue seems to be only relative to the EDIT: |
Thanks for debugging further. Moving I'm going to close this in favor of that issue. |
I have the following webpack config
When I run the build all workbox files are in the folder workbox-v3.4.1
But with webpack-dev-server I get a 404 when the service-worker.js tries to load
https://localhost:8080/workbox-v3.4.1/workbox-sw.js
As you can see I use workbox-webpack-plugin version 3.4.1
The text was updated successfully, but these errors were encountered: