Skip to content

sortupdate event not destroyed #13

Description

@yottaline

$('.sortable').sortable('destroy') doesn't destroy the sortupdate event
When I destroy it and make it stortable again with an update event it runs multiple times

Check my case here for a scroll loader

function load(){
    // load new products with ajax
    // append products to '.sortable' container
    $('.sortable').sortable('destroy');
    $('.sortable').sortable({
        items: ':not(.d-none)',
        placeholderClass: 'col-12 col-sm-4 col-md-3',
        handle: '.product-box',
    }).bind('sortupdate', sortUpdate);
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions