1 | import type { Atom, Scope, SetAtom, WritableAtom } from './atom';
|
2 | declare type Awaited<T> = T extends Promise<infer V> ? Awaited<V> : T;
|
3 | export declare function useAtom<Value, Update, Result extends void | Promise<void>>(atom: WritableAtom<Value, Update, Result>, scope?: Scope): [Awaited<Value>, SetAtom<Update, Result>];
|
4 | export declare function useAtom<Value>(atom: Atom<Value>, scope?: Scope): [Awaited<Value>, never];
|
5 | export {};
|