Hi!
Just installed the module to test as a replacement of select2. Found this error when changing from select2 to tagify one facet that already exists.
when the view with the facet loads, i get the error:
Uncaught ReferenceError: Sortable is not defined (tagify-widget.js:142:9)
Going to that line in modules/tagify_facets/js/tagify-widget.js
/**
* Binds Sortable to Tagify's main element and specifies draggable items.
*/
Sortable.create(tagify.DOM.scope, {
draggable: `.${tagify.settings.classNames.tag}:not(tagify__input)`,
forceFallback: true,
onEnd() {
tagify.updateValueByDOMTags();
},
});
checking hte definition in its libraries.yml, we dont see there core/sortable
nor in the definition of the JS
Enable both modules
Add a facet with tagify
see the console inspector of the browser
I have tried to add 'core/sortable' to tagify_facets.libraries.yml and then Sortable to the JS in lines 7 and 183 after once, but did not worked for me.
So i ended commenting lines 139-148 and the facet worked as expected.
Could be the Sortable was left there by mistake and is not needed?
Active
1.2
Code