question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Everything rendered after an Apex pie/donut will disappear if animations are disabled

See original GitHub issue

Code

<script src="https://cdn.jsdelivr.net/npm/apexcharts"></script>

<div id="chart"/>

<script>
    const options = {
        chart: {
            type: 'pie',
            width: 400,
            animations: {
                enabled: false
            }
        },
        series: [1,2,3],
    }
    var chart = new ApexCharts(document.querySelector("#chart"), options);
    chart.render();
</script>

This text will not be rendered if animations are disabled!!

Explanation

If animations are disabled (or set to speed=0), everything after the chart div will disappear. The above code demonstrates this. The text after the chart div will be visible for a very short period (flashes).

The same code with animations.speed=10 will work.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
msagerydcommented, Nov 2, 2021

Here’s a link to run the code you wrote, but the issue here is with <div id="chart"/> a self closing div is not valid and ends up parsing what you expect to be sibling elements into children elements. Changing this to <div id="chart"></div> solves this

Thanks @kevinhinterlong. I didn’t realize that this issue got answered. I don’t do much html, so I didn’t know this. Is it generally invalid with self-closing tags, or does it only relate to div?

0reactions
github-actions[bot]commented, Jan 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

animations - ApexCharts.js
Enable or disable all the animations that happen initially or during data update. ... Animate the chart when data is changed and chart...
Read more >
Disable Animation with Charts.js - javascript - Stack Overflow
If the parent element is responsive it may cause the chart to re-render and make it seem as if animations are not disabled....
Read more >
PowerPoint 2016: My Animations are Disabled ... - YouTube
If none of your animation effects are showing during presentation, maybe this is the reason.
Read more >
ComponentOne Chart for WPF - NET
CD (or disk) to ComponentOne, along with a dated proof of purchase, and ComponentOne will replace ... Disabling Chart Optimization After it has...
Read more >
Oracle Application Express App Builder Users Guide PDF
If this is software or related documentation that is delivered to the U.S. ... 2.3.1 How the Application Express Engine Renders and Processes...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found