From 46e63efd025ea5b9a5c81741ad93320c76a425e8 Mon Sep 17 00:00:00 2001 From: "autofix-ci[bot]" <114827586+autofix-ci[bot]@users.noreply.github.com> Date: Sat, 30 Nov 2024 09:30:29 +0000 Subject: [PATCH] ci: apply automated fixes and generate docs --- .../svelte/reference/functions/shallow.md | 2 +- .../svelte/reference/functions/usestore.md | 56 ++++++++++++++----- 2 files changed, 42 insertions(+), 16 deletions(-) diff --git a/docs/framework/svelte/reference/functions/shallow.md b/docs/framework/svelte/reference/functions/shallow.md index ec5fc24..06baf55 100644 --- a/docs/framework/svelte/reference/functions/shallow.md +++ b/docs/framework/svelte/reference/functions/shallow.md @@ -25,4 +25,4 @@ function shallow(objA, objB): boolean ## Defined in -[index.svelte.ts:39](https://github.com/TanStack/store/blob/main/packages/svelte-store/src/index.svelte.ts#L39) +[index.svelte.ts:43](https://github.com/TanStack/store/blob/main/packages/svelte-store/src/index.svelte.ts#L43) diff --git a/docs/framework/svelte/reference/functions/usestore.md b/docs/framework/svelte/reference/functions/usestore.md index eb7925e..e13dea5 100644 --- a/docs/framework/svelte/reference/functions/usestore.md +++ b/docs/framework/svelte/reference/functions/usestore.md @@ -5,40 +5,66 @@ title: useStore # Function: useStore() +## useStore(store, selector) + ```ts -function useStore(store, selector): object +function useStore(store, selector?): object ``` -## Type Parameters +### Type Parameters • **TState** • **TSelected** = `NoInfer`\<`TState`\> -• **TUpdater** *extends* `AnyUpdater` = `AnyUpdater` - -## Parameters +### Parameters -• **store**: `Store`\<`TState`, `TUpdater`\> +• **store**: `Store`\<`TState`, `any`\> -• **selector** = `...` +• **selector?** -## Returns +### Returns `object` -### current +#### current + +```ts +readonly current: TSelected; +``` -#### Get Signature +### Defined in + +[index.svelte.ts:10](https://github.com/TanStack/store/blob/main/packages/svelte-store/src/index.svelte.ts#L10) + +## useStore(store, selector) ```ts -get current(): TSelected +function useStore(store, selector?): object ``` -##### Returns +### Type Parameters -`TSelected` +• **TState** -## Defined in +• **TSelected** = `NoInfer`\<`TState`\> -[index.svelte.ts:10](https://github.com/TanStack/store/blob/main/packages/svelte-store/src/index.svelte.ts#L10) +### Parameters + +• **store**: `Derived`\<`TState`, `any`\> + +• **selector?** + +### Returns + +`object` + +#### current + +```ts +readonly current: TSelected; +``` + +### Defined in + +[index.svelte.ts:14](https://github.com/TanStack/store/blob/main/packages/svelte-store/src/index.svelte.ts#L14)