SortableJS/vue.draggable.next

TypeError: Cannot destructure property 'element' of 'undefined' as it is undefined.

luisrossi opened this issue · 4 comments

I copied and pasted this exact code:

But I'm getting this error:
TypeError: Cannot destructure property 'element' of 'undefined' as it is undefined.

"vuedraggable": "^4.0.1",
"vue": "^3.3.0",
"@vue/compat": "^3.3.0",

I also tried with the latest version of vuedraggable!
any suggestions on how to resolve this?

There's a very similar issue in floating-vue: Akryum/floating-vue#924

I think my comment from there applies here, too:

I don't think this library plays nicely with the compatibility build and the render function break.

The library works for us if we disable the RENDER_FUNCTION compatibility flag:

import {configureCompat} from 'vue';

configureCompat({
  RENDER_FUNCTION: false,
});

To solve this problem, I had to create myself a directive that does the tooltip behavior, using floating-ui/dom.

After migrating to vue 3, he intends to remove this created directive and use the one from the component.

#122 (comment)
@luisrossi this issue has been already answer here

Unfortunately it didn't work for me @davidphamntq
The solution for me was to migrate to another lib, vedraggableplus

Apparently this library has been abandoned