Exports the orderBy function.
- Source:
Requires
- module:lodash
Methods
(inner) orderBy(columns, orders, data) → {Array}
Executes the SQL ORDER BY statement on an Array of Objects
Parameters:
Name | Type | Description |
---|---|---|
columns |
Array | An Array of Strings, containing the columns that should get ordered. |
orders |
Array | An Array of Strings, containing the orders for the columns. |
data |
Array | The Array of Objects on which the ORDER BY statement should be executed. |
- Source:
Returns:
- An Array of Objects in the specified order.
- Type
- Array