@unction/mapkeyswithvaluekey
TypeScript icon, indicating that this package has built-in type declarations

9.13.0 • Public • Published

@unction/mapKeysWithValueKey

Tests Stability Dependencies

MapperFunctionType<A, MapperFunctionType<B, C>> => Array | Set | Record<string | number | symbol, B> | Map<B, A> | string => Array | Set | Record<string | number | symbol, B> | Map<C, B> | string

Map over keys with the context of the value and key.

const attributes = {
  name: "Kurtis Rainbolt-Greene",
  createdAt: new Date()
}

mapKeys((value) => (key) => )(attributes)

Would return:

{
  name: "Kurtis Rainbolt-Greene",
  "created-at": new Date()
}

Readme

Keywords

Package Sidebar

Install

npm i @unction/mapkeyswithvaluekey

Weekly Downloads

1

Version

9.13.0

License

SEE LICENSE IN LICENSE

Unpacked Size

20.8 kB

Total Files

7

Last publish

Collaborators

  • krainboltgreene