itaditya / trick-or-treat-game

Play it for free here
https://trick-or-treat.netlify.com/
16 stars 17 forks source link

Added service worker #33

Open xorob0 opened 4 years ago

xorob0 commented 4 years ago

I had to move the images inside /src for the service worker to be able to cache them automatically. An other solution would have been to add a list of assets to cache, but this solutions offer less flexibility as every new asset needs to be added in the list.

itaditya commented 4 years ago

Can you use Workbox instead of doing it from scratch. Workbox takes care of a lot of things and it is more maintainable.