import { $n as PluginRuntime } from "./types-B26yIFhw.js";

//#region src/plugin-sdk/runtime-store.d.ts
type PluginRuntimeStoreKeyOptions = {
  /** Explicit global registry key for shared runtime slots. */key: string; /** Error thrown by getRuntime before setRuntime initializes this slot. */
  errorMessage: string;
};
type PluginRuntimeStorePluginOptions = {
  /** Plugin id used to derive a stable cross-module runtime slot key. */pluginId: string; /** Error thrown by getRuntime before setRuntime initializes this slot. */
  errorMessage: string;
};
type PluginRuntimeStoreOptions = PluginRuntimeStoreKeyOptions | PluginRuntimeStorePluginOptions;
/** Create a tiny mutable runtime slot with strict access when the runtime has not been initialized. */
declare function createPluginRuntimeStore<T>(errorMessage: string): {
  setRuntime: (next: T) => void;
  clearRuntime: () => void;
  tryGetRuntime: () => T | null;
  getRuntime: () => T;
};
declare function createPluginRuntimeStore<T>(options: PluginRuntimeStoreOptions): {
  setRuntime: (next: T) => void;
  clearRuntime: () => void;
  tryGetRuntime: () => T | null;
  getRuntime: () => T;
};
//#endregion
export { type PluginRuntime, createPluginRuntimeStore };