mirror of
https://github.com/dzeiocom/libs.git
synced 2025-06-07 00:29:56 +00:00
Updated description of objectMap
Signed-off-by: Florian Bouillon <florian.bouillon@delta-wings.net>
This commit is contained in:
parent
c56cd074ec
commit
679291d7a8
@ -3,7 +3,7 @@
|
|||||||
*
|
*
|
||||||
* (Same as Array.map)
|
* (Same as Array.map)
|
||||||
* @param obj the object to remap
|
* @param obj the object to remap
|
||||||
* @param fn the fn to run
|
* @param fn the function to run for each key: value pairs
|
||||||
*/
|
*/
|
||||||
export function objectMap<T = any, J = any>(obj: Record<string, T>, fn: (value: T, key: string) => J): Array<J> {
|
export function objectMap<T = any, J = any>(obj: Record<string, T>, fn: (value: T, key: string) => J): Array<J> {
|
||||||
const list: Array<J> = []
|
const list: Array<J> = []
|
||||||
|
Loading…
x
Reference in New Issue
Block a user