hint Function | String | jQuery

Provides a way for customization of the sortable item hint. If a function is supplied, it receives one argument - the draggable element's jQuery object. If hint function is not provided the widget will clone dragged item and use it as a hint.

Important: The hint element is appended to the <body> tag. The developer should have this in mind in order to avoid styling issues.

Example - Sortable with custom hint

<ul id="sortable">

        hint: function(element) {
            return $("<span></span>")
                    .css("color", "#FF0000");
In this article