Skip to content

Commit

Permalink
ci: apply automated fixes and generate docs
Browse files Browse the repository at this point in the history
  • Loading branch information
autofix-ci[bot] authored Nov 30, 2024
1 parent 697d15e commit 46e63ef
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 16 deletions.
2 changes: 1 addition & 1 deletion docs/framework/svelte/reference/functions/shallow.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ function shallow<T>(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)
56 changes: 41 additions & 15 deletions docs/framework/svelte/reference/functions/usestore.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,66 @@ title: useStore

# Function: useStore()

## useStore(store, selector)

```ts
function useStore<TState, TSelected, TUpdater>(store, selector): object
function useStore<TState, TSelected>(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<TState, TSelected>(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)

0 comments on commit 46e63ef

Please sign in to comment.