Skip to Content

get Method

Retrieves the value associated with the specified key

@param key: string
The key for which to retrieve the value

@returns T

API

get(key: string): T;

Example

class ExampleSource<T = any> implements KeyValueSource<T> { private data: Index<T> = {}; get(key: string): T { return this.data[key]; } // ... }
Last updated on