26 lines
562 B
Markdown
26 lines
562 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
|
|
|
|
[Home](./index.md) > [@apextoaster/js-utils](./js-utils.md) > [mustGet](./js-utils.mustget.md)
|
|
|
|
## mustGet() function
|
|
|
|
Get an element from a Map and guard against nil values.
|
|
|
|
<b>Signature:</b>
|
|
|
|
```typescript
|
|
export declare function mustGet<TKey, TVal>(map: Map<TKey, TVal>, key: TKey): TVal;
|
|
```
|
|
|
|
## Parameters
|
|
|
|
| Parameter | Type | Description |
|
|
| --- | --- | --- |
|
|
| map | Map<TKey, TVal> | |
|
|
| key | TKey | |
|
|
|
|
<b>Returns:</b>
|
|
|
|
TVal
|
|
|