-
Notifications
You must be signed in to change notification settings - Fork 143
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
DragDropContext HMLT5Backend at top level of my app #31
Comments
I'm afraid there is no workaround I can think of right now since dazzle is coupled with react-dnd. Sorry about that! |
For my usage I declared a new component in dazzle called DashboardNoDndContext (that doesn't instantiate the DragDropContext) and rebuilt and it seems to be enough for my need. Obviously I also exported this DashboardNoDndContext in the index.js (not default export). |
That seems like a neat solution! Feel free to send a PR! how about |
Thanks I'll go for this PR |
Awesome! Two exports from the same file would be nice. We could remove the decorator and have an export which wraps the dashboard component with the Dnd context as you mentioned above. |
Hello, is any timeline for a release that will include this fix? |
Dazzle wraps its Dashboard Component with react-dnd's DragDropContext(HMLT5Backend)
I wish to use Dazzle in my application but also use react-dnd in another part of my component hierarchy which is not under the Dashboard component of Dazzle. So I would need to wrap my top most component in my React application with DragDropContext(HMLT5Backend). But whatever I do I will get the "Error: Cannot have two HTML5 backends at the same time" from react-dnd.
I think I'll not be able to do this without modifying Dazzle to not instantiate the DragDropContext in the Dashboard component. Am I right or is there a workaround that would not imply to modify Dazzle?
The text was updated successfully, but these errors were encountered: