src/chart/sunburst/sunburstLayout.js
function sort(children, sortOrder) {
    if (typeof sortOrder === 'function') {
        return children.sort(sortOrder);
    }
    else {
        var isAsc = sortOrder === 'asc';
        return children.sort(function (a, b) {
            var diff = (a.getValue() - b.getValue()) * (isAsc ? 1 : -1);
            return diff === 0
                ? (a.dataIndex - b.dataIndex) * (isAsc ? -1 : 1)
                : diff;
        });
    }
}
function sort(children, sortOrder) {
    if (typeof sortOrder === 'function') {
        return children.sort(sortOrder);
    }
    else {
        var isAsc = sortOrder === 'asc';
        return children.sort(function (a, b) {
            var diff = (a.getValue() - b.getValue()) * (isAsc ? 1 : -1);
            return diff === 0
                ? (a.dataIndex - b.dataIndex) * (isAsc ? -1 : 1)
                : diff;
        });
    }
}
function sort ( children , sortOrder ) { if ( typeof sortOrder === 'function' ) { return children . sort ( sortOrder ) ; } else { var isAsc = sortOrder === 'asc' ; return children . sort ( function ( a , b ) { var diff = ( a . getValue ( ) - b . getValue ( ) ) * ( isAsc ? 1 : - 1 ) ; return diff === 0 ? ( a . dataIndex - b . dataIndex ) * ( isAsc ? - 1 : 1 ) : diff ; } ) ; } }
Sort children nodes

@param {TreeNode[]}               children children of node to be sorted
@param {string | function | null} sort sort method
See SunburstSeries.js for details.
Sort children nodes