-
Notifications
You must be signed in to change notification settings - Fork 901
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple tree sharing data #29
Comments
It's not possible by default. I think it could be pulled off with some extra implementation, but I haven't ever looked into it. |
Ok, I will try to implement it and I can let you know about it when its done, if you are interested. Just one more thing, so I don't open a new issue here. Do you happen to have typescript definiton file? Thank you. |
Alright, that would be great! I don't have a typescript definition file. |
@zeljkohuber I'm also looking into this functionality, any luck so far? |
@arminconscia Still working on it but doing pretty big refactoring because its pretty hard to use it as separate components so I'm going with Redux implementation. |
@zeljkohuber Ahh okay, thanks for the reply, makes sense. |
@zeljkohuber I was looking into solving a similar situation but gave up trying to refactor, seemed to be to big of a rewrite. I ended up going for a non drag-and-drop solution. |
@larsts Main reason why I choose Redux is because I would then have separate components (source and destination tree) which would be much easier to integrate and Redux would be used for their communication. First solution I came up is creating container component (no Redux) which encapsulates both source and tree and handles their communication, but that way when you add container component in your project you don't have that much freedom of styling and moving inner components (source/dest), so I chose Redux to make that easier (another reason for Redux is because I'll need to integrate this component in angular2 application so Redux is the only way to communicate with angular2 as far as I know). The react-sortable-tree is so well written and structured that is pretty easy to make basic implementation with Redux, since all actions are already separated from the components so you just move state from component itself to Redux and reuse already implemented actions (from tree-data-utils.js) in reducers. |
@zeljkohuber That all sounds very good! And I'm sure more people than myself would be interested in having a look at the result / code when you have made it work :) |
@zeljkohuber I also have a need for this issue. https://github.com/vakata/jstree handles this quite well (esp when it comes to inter-tree communication), it may be worth a look there for inspiration. What parts of your implementation are still needed? |
@zeljkohuber - how'd your implementation go with redux? I'm working on something similar and would be curious to know how it all panned out. |
@matt-stj - we haven't worked on redux implementation as we've planned... |
Hi,
is it possible to have 2 trees, one being a source (for example 40 non nested "nodes"), and other being destination where source nodes could be dragged into and added (copy) dynamically? Is this something possible by default or needs additional implementation?
Regards
The text was updated successfully, but these errors were encountered: