Part 1 of core architecture fix - #881
Open
lee00678 wants to merge 3 commits into
Open
Conversation
…empty aliasing The class instance check tested the whole source object instead of the value under the current key, assigning the entire object to every merged key for class instance configs. cloneDeep already copies class instances by reference, so the branch is removed in favor of the default path. merge() now also returns a clone (instead of the original reference) when there is nothing to merge, so callers can never mutate a shared default config. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…without a config Components created without a config kept the module-level default config object as their own (via the `config = this._defaultConfig` initializer), so any mutation of `instance.config` polluted every other instance of the same component class (e.g. XYContainer setting `xAxis.config.type`). Constructors now always call `setConfig()`, which produces a private merged clone of the defaults. `XYComponentCore.setConfig` and `LeafletMap.setConfig` were hardened to tolerate an undefined config argument. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… Heatmap and LeafletFlowMap
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This MR cherry-picked two commits from https://github.com/f5/unovis/pull/878/commits
Core | Utils: Fix merge() class instance value handling and clone-on-empty aliasing
Component | All: Fix shared default config aliasing when constructed without a config
Fixed the setConfig on missing components (added later)