You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] openinula-vchart ignores data prop when spec is provided #4657
@visactor/openinula-vchart on develop at 0750d74cd6ea734e66897876506c78ca12680676
Link to Minimal Reproduction
Render <VChart spec={stableSpec} data={firstData} />, then re-render it with the same spec object and a different data value.
Steps to Reproduce
Create an OpenInula VChart with both the documented spec and data props.
Keep spec unchanged.
Replace data with a new dataset and re-render.
Current Behavior
BaseChart enters the hasSpec branch and compares only eventsBinded.current.spec with props.spec. Because the spec is unchanged, the effect returns without updating the chart. parseSpec also does not merge the separate data prop into spec, so the data prop is ignored on initial creation as well.
Expected Behavior
The OpenInula wrapper should honor its declared data prop with a supplied spec, both initially and on data-only updates.
Environment
OS: Windows 11
Node.js: 20.20.2 and 24.14.1
Package: @visactor/openinula-vchart
Any additional comments?
The React wrapper already implements the intended behavior: it merges data into a supplied spec and calls updateFullDataSync when only data changes. That support was added in commit d69cb49fb for #2443, but the equivalent logic is absent from the OpenInula wrapper. The OpenInula package currently has no focused tests for this lifecycle path, so a port should add coverage for both initial and data-only updates.
I searched open and closed issues and pull requests for OpenInula data updates, hasSpec, BaseChart, and updateFullDataSync; I reviewed #2443 and both wrappers' histories. #2443 is specifically about react-vchart and its fix did not update openinula-vchart. The repository has no Discussions, and I found no existing OpenInula report or fix.
Activity
dyk1454683243-sudo commentedon Sep 20, 2026
I'll take this: bring
@visactor/openinula-vchartdata+speclifecycle in line withreact-vchart.On current
develop, thehasSpecpath still ignoresprops.datainparseSpecand returns early when onlydatachanges. The port will:dataprop into the supplied spec on initial create ({ ...spec, data })updateFullDataSyncon data-only re-renders (samespecobject, newdata)There is no open PR with
Fixes #4657. This is separate from #4693 / #4678.dyk1454683243-sudo commentedon Sep 20, 2026
Opened #4694 (
Fixes #4657) againstdevelop— openinula-vchartdata+speclifecycle parity with react-vchart. Separate from #4693.fix: honor data prop when spec is supplied in openinula-vchart
dajiaohuang commentedon Oct 7, 2026
Thanks @dyk1454683243-sudo for submitting PR #4694 to fix this! Appreciate you addressing the openinula-vchart
data+speclifecycle parity issue.