UNPKG

@elgato/streamdeck

Version:

The official Node.js SDK for creating Stream Deck plugins.

30 lines (29 loc) 899 B
import type { JsonObject } from "@elgato/utils"; /** * Provides a cache for action settings, keyed by action instance identifier. */ declare class SettingsCache { #private; /** * Removes the cached settings for the specified action. * @param id Action instance identifier. */ delete(id: string): void; /** * Gets the cached settings for the specified action. * @param id Action instance identifier. * @returns The cached settings when present; otherwise `undefined`. */ get(id: string): JsonObject | undefined; /** * Sets the cached settings for the specified action. * @param id Action instance identifier. * @param settings The settings to cache. */ set(id: string, settings: JsonObject): void; } /** * Singleton instance of the settings cache. */ export declare const settingsCache: SettingsCache; export {};