dist/highlight-page.js
function sortByDepth(arr, descending) {
    arr.sort(function (a, b) {
        return dom(descending ? b : a).parents().length - dom(descending ? a : b).parents().length;
    });
}
function sortByDepth(arr, descending) {
    arr.sort(function (a, b) {
        return dom(descending ? b : a).parents().length - dom(descending ? a : b).parents().length;
    });
}
function sortByDepth ( arr , descending ) { arr . sort ( function ( a , b ) { return dom ( descending ? b : a ) . parents ( ) . length - dom ( descending ? a : b ) . parents ( ) . length ; } ) ; }
Sorts array of DOM elements by its depth in DOM tree.
@param {HTMLElement[]} arr - array to sort.
@param {boolean} descending - order of sort.
Sorts array of DOM elements by its depth in DOM tree .