Skip to content

chore: consolidate vite SW+main builds via Environment API#41047

Merged
pavelfeldman merged 1 commit into
microsoft:mainfrom
Skn0tt:vite-env
May 29, 2026
Merged

chore: consolidate vite SW+main builds via Environment API#41047
pavelfeldman merged 1 commit into
microsoft:mainfrom
Skn0tt:vite-env

Conversation

@Skn0tt
Copy link
Copy Markdown
Member

@Skn0tt Skn0tt commented May 29, 2026

Summary

  • Use Vite 6's Environment API to build each package's main + service worker bundles from a single Vite process, instead of one process per config file.
  • Reduces dev-time vite process count from 7 to 5 (trace-viewer SW and extension SW are no longer separate steps).
  • Deletes vite.sw.config.{ts,mts} in trace-viewer and extension; their config is now environments.sw in the main vite.config.
  • Output is byte-identical to before.

The trace-viewer and extension packages each had a separate
vite.sw.config for the service worker build, spawned as its own
'vite build --watch' process. Use Vite 6's Environment API to build
both environments from a single Vite process per package, reducing
the dev-time process count from 7 to 5.
@github-actions
Copy link
Copy Markdown
Contributor

Test results for "MCP"

7207 passed, 1113 skipped


Merge workflow run.

@github-actions
Copy link
Copy Markdown
Contributor

Test results for "tests 1"

2 flaky ⚠️ [chromium-library] › library/video.spec.ts:719 › screencast › should work with video+trace `@chromium-ubuntu-22.04-arm-node20`
⚠️ [playwright-test] › ui-mode-trace.spec.ts:812 › should update state on subsequent run `@windows-latest-node20`

43984 passed, 864 skipped


Merge workflow run.

@pavelfeldman pavelfeldman merged commit bc29607 into microsoft:main May 29, 2026
48 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants