@shared-state/core
Version:
The core package of `@shared-state`
4 lines (3 loc) • 355 B
TypeScript
import { ValueOrGetter, SharedState, DerivedSharedStateGetter, DerivedSharedStateSetter } from "./types";
export declare function createSharedState<T>(initialValueOrGetter: ValueOrGetter<T>): SharedState<T>;
export declare function createDerivedSharedState<T>(getter: DerivedSharedStateGetter<T>, setter?: DerivedSharedStateSetter<T>): SharedState<T>;