mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-06-02 06:29:40 +08:00
Merge pull request #26135 from zixia/zixia-patch-lru-cache
add the missing `key` arg for `length()`
This commit is contained in:
2
types/lru-cache/index.d.ts
vendored
2
types/lru-cache/index.d.ts
vendored
@@ -40,7 +40,7 @@ declare namespace LRU {
|
||||
* `max` like-sized things. The item is passed as the first argument,
|
||||
* and the key is passed as the second argument.
|
||||
*/
|
||||
length?(value: V): number;
|
||||
length?(value: V, key?: K): number;
|
||||
|
||||
/**
|
||||
* Function that is called on items when they are dropped from the cache.
|
||||
|
||||
Reference in New Issue
Block a user