Comments (5)
you can tie your SW to a version or git commit to force it to expire. We use our package.json version value for dockyard.com
from ember-service-worker.
Thanks @bcardarella! I guess you mean manually triggering navigator.serviceWorker.register
right? I can see doing this in different programmatic ways. We currently check for our latest git commit hash to prompt the user to refresh the page, I guess we can substitute refreshing for updating the SW... pretty straightforward 😄
Just wondering how do you handle it in dockyard.com using package.json version? Do you have a code snippet/service/addon?
Regards!
from ember-service-worker.
this addon has those strategies built in:
ember-service-worker/lib/index-file.js
Lines 15 to 17 in 2b42ecc
The strategy you want is the project version strategy.
from ember-service-worker.
@bcardarella awesome! We might consider versionStrategy: 'every-build'
as well
Thanks!
from ember-service-worker.
👍
from ember-service-worker.
Related Issues (20)
- Add tests for build process
- {{ROOT_URL}} not getting replaced during build on Windows when the code is on drive D:\
- Holistic approach to fetch settings
- Version 0.7.2 breaks Glimmer.js app HOT 4
- Prevent refresh on server update HOT 2
- sw-registration.js is fingerprinted incorrectly when rootURL is set. HOT 12
- Allow customization of service worker filename
- Problem with service worker registration HOT 15
- Uglify Writer error HOT 2
- Service Worker registration failed with TypeError: Failed to register a ServiceWorker HOT 6
- Unpeg @rollup/plugin-replace HOT 2
- Can't seem to install a custom service worker. HOT 2
- Ignoring URLs?
- Is `rootUrl` correct?
- ember config to service-worker
- Re-enable testing against multiple versions of Ember
- Installation fails on 9.0.0
- Embroider support HOT 3
- Why has version number jumped from v0.8.x to v9.0.0?
- Documentation links to unexisting website HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ember-service-worker.