withDictionaryItemsconstant
withDictionaryItems: <T>(dict: ImmutableDictionary<T>, props: PossibleDictionary<T>) => ImmutableDictionary<T>
| Return | |
|---|---|
unknown | A new dictionary including the set items, or the original dictionary if all values were unchanged. |
Set several items on a dictionary object (immutably) and return a new object including those items.
- If all values are unchanged the original dictionary is returned unchanged.
Examples
withDictionaryItems({ a: 1 }, { b: 2, c: 3 }); // { a: 1, b: 2, c: 3 }