mirror of
https://github.com/laoxong/nofx.git
synced 2026-06-07 11:17:56 +08:00
5aa50d35d7
- Multi-AI competition mode (Qwen vs DeepSeek) - Binance Futures integration - AI self-learning mechanism - Professional web dashboard - Complete risk management system
15 lines
934 B
TypeScript
15 lines
934 B
TypeScript
import type { ExtractState, Mutate, StateCreator, StoreApi, StoreMutatorIdentifier } from 'zustand/vanilla';
|
|
type ReadonlyStoreApi<T> = Pick<StoreApi<T>, 'getState' | 'getInitialState' | 'subscribe'>;
|
|
export declare function useStore<S extends ReadonlyStoreApi<unknown>>(api: S): ExtractState<S>;
|
|
export declare function useStore<S extends ReadonlyStoreApi<unknown>, U>(api: S, selector: (state: ExtractState<S>) => U): U;
|
|
export type UseBoundStore<S extends ReadonlyStoreApi<unknown>> = {
|
|
(): ExtractState<S>;
|
|
<U>(selector: (state: ExtractState<S>) => U): U;
|
|
} & S;
|
|
type Create = {
|
|
<T, Mos extends [StoreMutatorIdentifier, unknown][] = []>(initializer: StateCreator<T, [], Mos>): UseBoundStore<Mutate<StoreApi<T>, Mos>>;
|
|
<T>(): <Mos extends [StoreMutatorIdentifier, unknown][] = []>(initializer: StateCreator<T, [], Mos>) => UseBoundStore<Mutate<StoreApi<T>, Mos>>;
|
|
};
|
|
export declare const create: Create;
|
|
export {};
|