<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [rc-js-util](./rc-js-util.md) &gt; [mapUnion](./rc-js-util.mapunion.md)

## mapUnion() function

Returns a map with keys from both A and B. If both A and B have the same key the value from B will be used.

**Signature:**

```typescript
export declare function mapUnion<TKey, TIem>(a: ReadonlyMap<TKey, TIem>, b: ReadonlyMap<TKey, TIem>): Map<TKey, TIem>;
```

## Parameters

<table><thead><tr><th>

Parameter


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

a


</td><td>

ReadonlyMap&lt;TKey, TIem&gt;


</td><td>


</td></tr>
<tr><td>

b


</td><td>

ReadonlyMap&lt;TKey, TIem&gt;


</td><td>


</td></tr>
</tbody></table>
**Returns:**

Map&lt;TKey, TIem&gt;

## Remarks

See [mapUnion()](./rc-js-util.mapunion.md)<!-- -->.

