useStore

函数: useStore()

调用签名

ts
function useStore<TState, TSelected>(store, selector?): Accessor<TSelected>
function useStore<TState, TSelected>(store, selector?): Accessor<TSelected>

定义于: index.tsx:12

类型参数

TState

TSelected = NoInfer<TState>

参数

store

Store<TState, any>

选择器?

(state) => TSelected

Returns (返回)

Accessor<TSelected>

调用签名

ts
function useStore<TState, TSelected>(store, selector?): Accessor<TSelected>
function useStore<TState, TSelected>(store, selector?): Accessor<TSelected>

定义于: index.tsx:16

类型参数

TState

TSelected = NoInfer<TState>

参数

store

Derived<TState, any>

选择器?

(state) => TSelected

Returns (返回)

Accessor<TSelected>

我们的合作伙伴
Code Rabbit
订阅 Bytes

您的每周 JavaScript 资讯。每周一免费发送给超过 10 万开发者。

Bytes

无垃圾邮件。您可以随时取消订阅。

订阅 Bytes

您的每周 JavaScript 资讯。每周一免费发送给超过 10 万开发者。

Bytes

无垃圾邮件。您可以随时取消订阅。