sort method

List<T> sort(
  1. List<T> items
)

Sorts a list of items according to this sort order.

Implementation

List<T> sort(List<T> items) {
  final sorted = List<T>.from(items);
  sorted.sort(compare);
  return sorted;
}