Skip to content

Version 4.0.0 introduces "'appendChild' on 'Node': parameter 1 is not of type 'Node'" issue #4828

@mrash

Description

@mrash

Description

In Apexcharts version 4.0.0 there is a new issue related to chart.render() where the error "'appendChild' on 'Node': parameter 1 is not of type 'Node'" is thrown.

Steps to Reproduce

  1. Use the ap_pie.html file in this gist.
  2. By default, the ap_pie.html file points to the CDN to acquire Apexcharts.
  3. Note that the pie chart to the right of the area chart is not rendered. In a browser console, the error "'appendChild' on 'Node': parameter 1 is not of type 'Node'" is thrown.
  4. This issue does not happen in Apexcharts 3.54.1 and prior releases. Perhaps this is related to the Svgjs 3.2 upgrade? If so, what is the proper way to use chart.render()?

Expected Behavior

The expected behavior is for the pie chart to be rendered from the ap_pie.html file in this gist. In Apexcharts 3.54.1 and previous releases, the pie chart is rendered.

Actual Behavior

When pointing to Apexcharts 4.0.0 (via the CDN which the ap_pie.html file does by default), the pie chart is not rendered, and the "appendChild" error mentioned above in the description is thrown.

Screenshots

Here is a screenshot using Apecharts 3.54.1:
Screenshot 2024-11-24 at 6 05 55 PM

Here is a screenshot of the same file but using Apexcharts 4.0.0 (via the CDN):
Screenshot 2024-11-24 at 6 01 16 PM

Reproduction Link

The ap_pie.html file in this gist reproduces the problem and was used to create the screenshots above.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions