shadowwalker / next-pwa

Zero config PWA plugin for Next.js, with workbox 🧰
MIT License
3.71k stars 312 forks source link

worker.ts with next-pwa does not create sw.js #500

Open vporton opened 7 months ago

vporton commented 7 months ago

Summary

It's also automatically injected into sw.js generated.

from https://github.com/shadowwalker/next-pwa/tree/master/examples/custom-ts-worker

After npm run build the search find -name sw.js does not finds nothing. So sw.js isn't generated.

My project: https://github.com/vporton/carbon-flow_colony/tree/86c1013c88f7608a6c6484cb911cf1ef6ba10c9b

Versions

How To Reproduce

Steps to reproduce the behavior:

  1. Download my project
  2. npm i
  3. npm run build
  4. find -name sw.js
  5. The file is not found.

Expected Behaviors

Create sw.js file, because it is so documented.

Additional Context

If sw.js should not be generated, update your docs at https://github.com/shadowwalker/next-pwa/tree/master/examples/custom-ts-worker