Page Contents
Home > @loopback/repository > getKeyValue
getKeyValue() function
Returns value of a keyName. Aims to resolve ObjectId problem of Mongo.
Signature:
export declare function getKeyValue(model: AnyObject, keyName: string): unknown;
Parameters
Parameter | Type | Description |
---|---|---|
model | AnyObject | target model |
keyName | string | target key that gets the value from |
Returns:
unknown