d3/d3-hierarchy

the json result convert to d3-hierarchy can not generate the correct format without children

EthanAnro opened this issue · 1 comments

my question is: how can I get correct hierarchy type then generate the correct collapsible Tree?
d3 Version: v6.1 which is the latest version.
call for d3 function:
image
the root after the hierarchy call :
image
the undefined children property:
image
my json data:
image
My web:
image
The html info generated by d3 :
image

Fil commented

Hello,

Quite a few examples of d3-hierarchy are available at Observable and blockbuilder.

To ask for help, please use the Stack Overflow tag d3.js. Thousands of D3-related questions have been asked there, and some answers may be relevant to you.

When asking for help, please include a link to demonstrate the issue, preferably as an Observable notebook. It is often impossible to debug from code snippets alone. Isolate the issue and reduce your code as much as possible before asking for help. The less code you post, the easier it is for someone to debug, and the more likely you are to get a helpful response.

If you have a question about D3’s behavior and want to discuss it with other users, also consider the d3-js Google Group or joining the d3-js Slack.

Thank you! 🤖