import { Store, StoreValue } from "nanostores"; import { DeepReadonly, ShallowRef, UnwrapNestedRefs } from "vue"; //#region src/vue/vue-store.d.ts /** What {@link useStore} returns: a readonly reactive ref of the store value. */ type ReactiveValue = DeepReadonly>>; /** * Subscribe a Vue component to a nanostores store. * * Modeled on `@nanostores/vue`'s `useStore`: a `shallowRef` mirrors the store * value, `subscribe` keeps it in sync (firing once immediately), and the * listener is torn down on scope dispose. On the server (no `window`) it reads * once without subscribing, so a store seeded with `initialSession` renders * without leaving a subscription behind. */ declare function useStore(store: SomeStore): ReactiveValue>; //#endregion export { ReactiveValue, useStore };