Skip to content

Render reported before complete #2124

@drewdaemon

Description

@drewdaemon

Describe the issue
The library is reporting a complete render one tick too early.

To Reproduce
Add a breakpoint or log statement to the body of the onRenderChange callback for a chart.

Expected behaviour
onRenderChange should only be called with true when the chart has been rendered to the canvas. Instead, it is being called a tick before the chart is drawn.

Screenshots

Screen.Recording.2023-08-02.at.10.14.03.AM.mov

Look for "visualization took to render after data received" in the above recording ^^. It is logged before the chart is visible.

Version (please complete the following information):

  • OS: OSX
  • Browser: Brave, Safari
  • Elastic Charts: 59.1.0

Additional context
This behavior throws off our performance measurements, making it look like we're rendering the chart faster than we actually are.

The problem may originate with this change.

Errors in browser console
None

Metadata

Metadata

Assignees

No one assigned

    Labels

    :allApplies to all chart typesAPIChanges the external API typesenhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions