Skip to content
GitLab
    • Explore Projects Groups Snippets
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C create-react-app
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,547
    • Issues 1,547
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 417
    • Merge requests 417
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • create-react-app
  • Merge requests
  • !6725

Update to workbox-webpack-plugin v4

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Administrator requested to merge github/fork/r0ughnex/feature/update-to-workbox-webpack-plugin-v4 into master 6 years ago
  • Overview 5
  • Commits 2
  • Pipelines 0
  • Changes 1

Created by: r0ughnex

DESCRIPTION:

  • Resolves #6659 (closed): Updated the workbox-webpack-plugin from v3 to latest v4 and also tested some of the new configuration options such as skipWaiting and cleanupOutdatedCaches after ejecting the app.

  • Resolves #6243 (closed): The new version automatically solves the issue where a registered service worker still tries to load an old resource, after workbox has cleaned up its old cache after an update.

TESTS COMPLETED:

  • Change the app code to serviceWorker.register() and run build, then check if workbox caches the relevant files and if the service worker installs correctly and triggers the onSuccess callback.

  • Add flag skipWaiting: true to the webpack.config.js, then update the app code and perhaps also the version number in package.json, then repeat the test above and check if the new service worker takes over the application and triggers the onUpdate callback. Older outdated workbox caches should be deleted at the point (from logs visible on the dev console in localhost)

  • Add flag cleanupOutdatedCaches: false, repeat the test above and check if the new service worker takes over the application. Older outdated workbox cache should not deleted now (this option is only available in versions 4.x.x and above).

Approval is optional

Merged by (Jul 25, 2025 12:07pm UTC)

Merge details

  • Changes merged into master with cbe4c62f.
  • Deleted the source branch.

Activity


  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator requested review from @root 6 years ago

    requested review from @root

  • Administrator added CLA Signed label 6 years ago

    added CLA Signed label

  • Administrator
    Administrator @root · 6 years ago
    Author Contributor

    Created by: r0ughnex

    @iansu: This is my first ever contribution to create-react-app, so thanks for letting me take this up. I tried my best to test the new version of the plugin under a few scenarios (before and after ejecting). Let me know if I need to do anything else.

  • Administrator assigned to @root 6 years ago

    assigned to @root

  • Administrator changed milestone to %3.0 6 years ago

    changed milestone to %3.0

  • Administrator
    Administrator @root · 6 years ago
    Author Contributor

    Created by: jadbox

    This workbox update is important as it improves a number of things, including adding the much needed skipWaiting() message handler (which I'd had to otherwise manually inject in dozens of CRA projects): GoogleChrome/workbox#1929

  • Administrator mentioned in issue #6686 (closed) 6 years ago

    mentioned in issue #6686 (closed)

  • Administrator
    Administrator @root · 6 years ago
    Author Contributor

    Created by: jadbox

    @iansu this is a pretty simple change and should be backwards compatible. Can we get this into v2.x instead of holding this back until v3 milestone?

  • Administrator
    Administrator @root · 6 years ago
    Author Contributor

    Created by: iansu

    We are not planning to do any more releases of the 2.x line. We are hoping to release 3.0 in the very near future so this should be available soon.

  • Administrator closed 6 years ago

    closed

  • Administrator reopened 6 years ago

    reopened

  • Administrator
    Administrator @root · 6 years ago
    Author Contributor

    Merged by: iansu at 2019-04-05 15:48:02 UTC

  • Administrator closed 6 years ago

    closed

  • Administrator added tag: underlying tools label 6 years ago

    added tag: underlying tools label

Please register or sign in to reply
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Labels
2
CLA Signed tag: underlying tools
2
CLA Signed tag: underlying tools
    Assign labels
  • Manage project labels

Milestone
3.0
3.0
None
Time tracking
No estimate or time spent
Lock merge request
Unlocked
1
1 participant
Administrator
Reference: facebook/create-react-app!6725
Source branch: github/fork/r0ughnex/feature/update-to-workbox-webpack-plugin-v4

Menu

Explore Projects Groups Snippets