Skip to content

Update react-vega to v8 and adapt VegaChart accordingly#141

Open
clarasb wants to merge 7 commits intomainfrom
clarasb-132-update_VegaChart
Open

Update react-vega to v8 and adapt VegaChart accordingly#141
clarasb wants to merge 7 commits intomainfrom
clarasb-132-update_VegaChart

Conversation

@clarasb
Copy link
Collaborator

@clarasb clarasb commented Mar 3, 2026

This PR:

  • updates react-vega to v8 and adapts VegaChart accordingly (see rect-vega migration guide)
  • removes altair pinning. This is not necessary anymore
  • integrates VegaChart component in testing (after beeing excluded in Update vega #131)

Closes #132.

@codecov
Copy link

codecov bot commented Mar 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.85%. Comparing base (794871e) to head (29d530e).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #141      +/-   ##
==========================================
+ Coverage   92.22%   92.85%   +0.63%     
==========================================
  Files          87       87              
  Lines        1504     1525      +21     
  Branches      231      232       +1     
==========================================
+ Hits         1387     1416      +29     
+ Misses         98       91       -7     
+ Partials       19       18       -1     
Flag Coverage Δ
backend 100.00% <ø> (ø)
frontend 85.44% <100.00%> (+1.51%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@clarasb clarasb marked this pull request as ready for review March 4, 2026 11:18
@clarasb clarasb requested review from b-yogesh and forman March 4, 2026 11:19
Copy link
Collaborator

@b-yogesh b-yogesh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Clara, it LGTM! Did you also test this out in a fresh node environment and the demos work as expected?

// Keep cleanup in a ref so it can run on re-embed and unmount.
const cleanupRef = useRef<null | (() => void)>(null);

const onEmbed = useCallback(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Move into hook in a separate module because it is too much logic here.

- python >=3.10,<3.14
# Optional Dependencies
- altair>=5.5.0,<6.0.0
- altair
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is a lib dependency, you must limit its range.

[project.optional-dependencies]
opt = [
"altair>=5.5.0,<6.0.0",
"altair",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Limit range, see above.

]
demo = [
"altair>=5.5.0,<6.0.0",
"altair",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See above

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.

Update VegaCharts component

3 participants