API Reference@grafana/datasortValues

arrayUtils.sortValues() function

arrayUtils.sortValues() function

Signature

export declare function sortValues(sort: SortOrder.Ascending | SortOrder.Descending): (a: any, b: any) => number;

Import

import { arrayUtils } from '@grafana/data';
const { sortValues } = arrayUtils;

Parameters

ParameterTypeDescription
sortSortOrder.Ascending | SortOrder.Descending

Returns:

(a: any, b: any) => number