fix: CHARTS-6412 Update timeline example to wait for rendering #58
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.
Given the
v1.30update of Charts, the promise return from embedded chart'srenderandrefreshmethods will now wait for data to fetch.With the timeline example, if you were to interact with the example whilst the chart is still loading, an error will be shown. This PR disables the interactive controls on the timeline example and enables them once all Charts have been rendered.
I have checked all other examples in this repo and believe that this does not occur anywhere else.
Before
Interact with the interactive controls before charts have been rendered.
Screen.Recording.2022-02-14.at.3.12.49.pm.mp4
After
Interactive controls have been disabled.
Screen.Recording.2022-02-14.at.3.14.27.pm.mp4