1.1.2 • Published 7 years ago
@unction/nestedobjof v1.1.2
@unction/nestedObjOf
(KeyType | Array<KeyType) -> any -> IterableType
Given a path and a value, it creates an object that has keys based on the path.
nestedObjOf(["key", "subkey"])("value")
Which returns:
{
key: {
subkey: "value"
}
}