@atlaskit/editor-plugin-interactivity
Version:
Interactivity plugin for @atlaskit/editor-core
10 lines (9 loc) • 353 B
TypeScript
/** A `Map` that forgets its oldest entry once it holds more than `limit`. */
export declare class BoundedMap<Key, Value> {
private readonly limit;
private readonly entries;
constructor(limit: number);
get(key: Key): Value | undefined;
forEach(visit: (value: Value, key: Key) => void): void;
set(key: Key, value: Value): void;
}