Hi,
Could you help me with this problem, please?
I try to use SortableTree with touch support. I copied code sample (touch-support) from storybook app and when i try to use this:
import { SortableTreeWithoutDndContext as SortableTree } from "react-sortable-tree";
instead of this
import SortableTree from "react-sortable-tree";
I got error:

I have prepared a code sample to reproduce the error
https://codesandbox.io/s/ov1n19x0r5
I tried sample from your sandbox https://codesandbox.io/s/1r3vz5mmyj from this page and is not working too. Error the same.
It seems that the problem is related to the version of react-dnd library. If you use the version 3.0.2 it works!
But if you switch to the latest 5.0.1 version you receive an error as above.
so many react dnd bugs #336 .... :(
@slemvs , @wuweiweiwu I attempted an upgrade but the react-dnd is now using the latest this.context which breaks many parts in the code... will try again when I have a solid block of time to resolve this or @wuweiweiwu, I saw your comments that you will take a look?
@lifejuggler Thanks for taking a look! I was planning on it. But havent had time recently.
Hi! Is there a workaround to this problem until it get's solved?
@votiv Yes, just switch the version of react-dnd from latest to 3.0.2. In my case it helped.
https://codesandbox.io/s/98kj095wwy
@slemvs Unfortunately downgrading react-dnd to 3.0.2 did not work... Still same error.
@slemvs Unfortunately downgrading react-dnd to 3.0.2 did not work... Still same error.
@NoureldeanSaed There is a working example https://codesandbox.io/s/98kj095wwy. Please, check all dependencies versions in it.
Most helpful comment
@votiv Yes, just switch the version of react-dnd from latest to 3.0.2. In my case it helped.
https://codesandbox.io/s/98kj095wwy