src code

instance method Enumerable#sortBy

Enumerable#sortBy(iterator[, context]) → Array

Provides a custom-sorted view of the elements based on the criteria computed, for each element, by the iterator.