frontend-collective / frontend-collective/react-sortable-tree

Can't make sense of Path

Open
#383 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
5k
Forks
914
PR merge metrics
No merged PRs in 30d

Description

Hi,

I can't make sense of the path, I wondering if there is an issue.
I have a simple tree, no dragging, no change in it:
- 2 nodes at the root level ((2) [{…}, {…}])
- 2 nodes as a child of the first root node, 1 child for the second root node
The tree displays correctly and it's great (good job on the library).

The path of first child of the first root node is 0:1 and second child 0:2. That could make sense but I would expect 0:0 and 0:1 (index value).

Now, the path of the second root node tells me 0:3, which doesn't make sense to me. And then the child of that node is 0:3 0:4.

Is that an error ? Otherwise can someone explain ?

Thanks

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.