Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: use Vite official API for building sw.js (#20894) (CP: 24.5) #20916

Merged
merged 2 commits into from
Jan 27, 2025

Conversation

tepi
Copy link
Contributor

@tepi tepi commented Jan 27, 2025

  • fix: fix service worker build

  • fix PwaTestIT

  • exclude sw.js from manifest

  • generate service worker at closeBundle stage

  • clean up service worker build config

  • generate service worker at different stages depending on mode

  • do not use lib mode to allow for minification in es format

  • clean up plugin code

  • add inlineDynamicImports: true option

  • revert some changes to minimize diff

  • add exports option for backward compatibility


Description

Please list all relevant dependencies in this section and provide summary of the change, motivation and context.

Fixes # (issue)

Type of change

  • Bugfix
  • Feature

Checklist

  • I have read the contribution guide: https://vaadin.com/docs/latest/guide/contributing/overview/
  • I have added a description following the guideline.
  • The issue is created in the corresponding repository and I have referenced it.
  • I have added tests to ensure my change is effective and works as intended.
  • New and existing tests are passing locally with my change.
  • I have performed self-review and corrected misspellings.

Additional for Feature type of change

  • Enhancement / new feature was discussed in a corresponding GitHub issue and Acceptance Criteria were created.

* fix: fix service worker build

* fix PwaTestIT

* exclude sw.js from manifest

* generate service worker at closeBundle stage

* clean up service worker build config

* generate service worker at different stages depending on mode

* do not use lib mode to allow for minification in es format

* clean up plugin code

* add inlineDynamicImports: true option

* revert some changes to minimize diff

* add exports option for backward compatibility

---------

Co-authored-by: Teppo Kurki <teppo.kurki@vaadin.com>
@tepi tepi changed the title refactor: use Vite official API for building sw.js (#20894) refactor: use Vite official API for building sw.js (#20894) (CP: 24.5) Jan 27, 2025
Copy link

Test Results

1 148 files  ± 0  1 148 suites  ±0   1h 27m 25s ⏱️ -31s
7 540 tests ± 0  7 487 ✅ ± 0  53 💤 ±0  0 ❌ ±0 
7 851 runs  +30  7 788 ✅ +24  63 💤 +6  0 ❌ ±0 

Results for commit 4a88b13. ± Comparison against base commit b676d6f.

@tepi tepi merged commit d98a050 into 24.5 Jan 27, 2025
26 checks passed
@tepi tepi deleted the fix/fix-service-worker-build-cp-24.5 branch January 27, 2025 12:02
@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Vaadin 24.5.11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants