UNPKG

@cran/gql.core

Version:

Cran/GraphQL Core Utilities

9 lines (8 loc) 617 B
export interface LikeExtendable { extensions?: null | Record<string, unknown>; } export declare function getExtensions(extendable: LikeExtendable): Record<string, unknown>; export declare function hasExtension(extendable: LikeExtendable, key: symbol | string): boolean; export declare function getExtension<T = unknown>(extendable: LikeExtendable, key: symbol | string): T | undefined; export declare function getExtension<T = unknown>(extendable: LikeExtendable, key: symbol | string, fallback: T): T; export declare function setExtension(extendable: LikeExtendable, key: symbol | string, value: unknown): void;