UNPKG

rambdax

Version:

Extended version of Rambda - a lightweight, faster alternative to Ramda

9 lines (6 loc) 224 B
import { path } from './path' import { sortBy } from './sortBy' export function sortByPath(sortPath, list){ if (arguments.length === 1) return _list => sortByPath(sortPath, _list) return sortBy(path(sortPath), list) }