Skip to content

[9.2] [deps] Update vega to 6.x (#238618)#245387

Merged
markov00 merged 1 commit intoelastic:9.2from
markov00:backport/9.2/pr-238618
Dec 5, 2025
Merged

[9.2] [deps] Update vega to 6.x (#238618)#245387
markov00 merged 1 commit intoelastic:9.2from
markov00:backport/9.2/pr-238618

Conversation

@markov00
Copy link
Copy Markdown
Contributor

@markov00 markov00 commented Dec 5, 2025

Backport

This will backport the following commits from main to 9.2:

Questions ?

Please refer to the Backport tool documentation

## Summary

Update Vega dependencies to 6.x.

This pull request updates the project's Vega and Vega-Lite dependencies
to their latest major versions.

**Dependency Upgrades and Import Handling**

- Upgraded `vega`, `vega-lite`, `vega-interpreter`, `vega-tooltip`, and
related libraries to their latest major versions in `package.json`, and
updated their import paths throughout the codebase.

- Removed legacy Webpack and Storybook configuration for the old `vega`
build, including `noParse` rules and aliases, and updated the import
resolver to point to the new `vega-lite` and `vega-tooltip` build
directories.

**Testing and TypeScript Support**

- Added a Jest setup mock for `vega` and `vega-lite` to ensure tests run
correctly with the new versions, and updated Jest transform ignore
patterns to support new Vega-related packages.
- Updated `tsconfig.base.json` to include type definitions for
`vega-lite` and `vega-tooltip`.

**Babel and Build Tools**

- Added `@babel/plugin-syntax-import-attributes` to dependencies and
Babel preset to enable the new import attributes syntax.

**Test Snapshots**

- Updated Vega visualization test snapshots to reflect the new
rendering/output from upgraded dependencies.

---------

Co-authored-by: Tiago Costa <tiago.costa@elastic.co>
(cherry picked from commit d8c23ae)

# Conflicts:
#	package.json
#	src/platform/packages/shared/kbn-test/jest-preset.js
@markov00 markov00 added the backport This PR is a backport of another PR label Dec 5, 2025
@markov00 markov00 enabled auto-merge (squash) December 5, 2025 13:41
@elasticmachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
ml 2551 3905 +1354
visTypeVega 567 1736 +1169
total +2523

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
ml 5.4MB 5.4MB -43.2KB
visTypeVega 2.0MB 2.0MB -58.8KB
total -102.0KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
visTypeVega 34.3KB 34.3KB -3.0B

@markov00 markov00 merged commit 2226a78 into elastic:9.2 Dec 5, 2025
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants