oliviertassinari / serviceworker-webpack-plugin

Simplifies creation of a service worker to serve your webpack bundles. :recycle:
https://oliviertassinari.github.io/serviceworker-webpack-plugin/
MIT License
458 stars 76 forks source link

Module not found: Error: Can't resolve 'serviceworker-webpack-plugin/lib/runtime' #67

Open yyn835314557 opened 6 years ago

yyn835314557 commented 6 years ago

I Register the service worker in the main JS thread: import runtime from 'serviceworker-webpack-plugin/lib/runtime';

errors as follows

ERROR in ./src/views/index/index.js
Module not found: Error: Can't resolve 'serviceworker-webpack-plugin/lib/runtime' in '/Users/XXX/front-end/webapps/src/views/index'
 @ ./src/views/index/index.js 43:15-66
 @ ./src/route/menuroutedata.js
 @ ./src/route/index.js
 @ ./src/index.js
 @ multi webpack-hot-middleware/client ./src/index

but I have already install the pulgin, image

thanks a lot

woutervanvliet commented 6 years ago

Would you be able to setup a repo that reproduces the issue with the least amount of code necessary?

anusm14 commented 5 years ago

Did you find solution for this problem.?Facing the same issue.