Add SW push/sync feature in dev mode
What kind of change does this PR introduce? (check at least one)
- [ ] Bugfix
- [x] Feature
- [ ] Code style update
- [ ] Refactor
- [ ] Build-related changes
- [ ] Other, please describe:
Does this PR introduce a breaking change? (check one)
- [ ] Yes
- [x] No
If yes, please describe the impact and migration path for existing applications:
The PR fulfills these requirements:
- [x] It's submitted to the
devbranch and not themasterbranch - [ ] When resolving a specific issue, it's referenced in the PR's title (e.g.
fix: #xxx[,#xxx], where "xxx" is the issue number) - [ ] It's been tested on Windows
- [x] It's been tested on Linux
- [ ] It's been tested on MacOS
- [ ] Any necessary documentation has been added or updated in the docs (for faster update click on "Suggest an edit on GitHub" at bottom of page) or explained in the PR's description.
If adding a new feature, the PR's description includes:
- [ ] A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)
Other information: The PR extends the Quasar-cli behaviour in Dev mode : It make it able to deliver the no-op service worker, but also a push and a sync part of code for managing this SW events by separating the source code. The point is that the content of to files is append at the end of the generated no-op SW.
Here is the first part of the job to make PWA more easy to run in dev mode. As discuted on the Forum the previous way to play with SW in dev mode was "not efficient".
Now I need help to make it run in build mode : I read the code and found in the webpack-config.js (line 353) a possible place to add this, but I'm not very sure how to inject the push and sync part at the end of the service-worker.js : Any idea ?
Then, when I will get the info for build injection, I'll be able to update the documentation.
Best regards