Replies: 1 comment
|
Thank you for your proposal! Haven't really thought a lot about this before, but you are right. f i try to imagine a new person trying this package, i guess he'd be confused abiyt tgus... On the list then, i lean towards this 2nd option btw! |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
The first time I used the package, I found it a bit difficult to quickly understand the purpose of the
ActionOnNodeRemovalenum. When calling theremoveItemmethod, I naturally expected the action to refer to the removal of the node itself.It was only after looking into the source code that I realized the enum actually refers to how the descendant nodes should be handled when a node is removed.
To improve clarity and readability, I’d like to suggest a potential adjustment to this enum — if it makes sense to you as well.
I see two possible options:
Option 1 – Rename the enum to DescendantsActionOnNodeRemoval:
Option 2 – Rename the enum values to make their purpose explicit:
In both cases, the goal is to make it immediately clear that the enum controls the behavior applied to descendants of the node being removed, rather than the node itself. Let me know what you think!
All reactions