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 file cannot be imported directly into project from node_modules #7

Open
abitshaken opened this issue Aug 11, 2021 · 0 comments

Comments

@abitshaken
Copy link
Contributor

Since service workers are written in vanilla javascript, modular specifiers for importing the library does not work since the browser does not have access to the node_modules directory. So the library needs to be copied into the root directory and the service worker needs to import the static endpoint. If there is a way to leverage a transcompiler or a bundler to load the library in a way the browser can access it while still using modular specifiers, then it would be a big win.

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