Skip to content

Commit 4d87a83

Browse files
feat: new hooks and actions APIs (#306)
* chore: migrate builds to tsdown and upgrade all deps * changeset * clean up solid exports and node types overrides * reapply exports in package jsons * add back yaml * fix yaml config that was accidentally deleted * format * feat: new set of react hooks * ci: apply automated fixes and generate docs * fix package.jsons * feat: add actions to stores (#307) * feat: add actions to stores * ci: apply automated fixes and generate docs * simplify context hook impl * ci: apply automated fixes and generate docs * feat: introduce more frameworks hooks for other non-react adapters (#308) * feat: introduce more frameworks hooks for other non-react adapters * new changeset * ci: apply automated fixes and generate docs * remove dedicated setValue and useAction hooks. Add new useStore hooks with _ * ci: apply automated fixes and generate docs --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> * also bind subscribe * replace `new Store` with createStore in examples * remove useValue, make selector optional in useSelector * add solid context helper * update changeset * format * improve store action examples * fix some api ref docs links --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
1 parent 840b9d0 commit 4d87a83

337 files changed

Lines changed: 13023 additions & 2157 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.changeset/hooks.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
'@tanstack/angular-store': minor
3+
'@tanstack/preact-store': minor
4+
'@tanstack/svelte-store': minor
5+
'@tanstack/react-store': minor
6+
'@tanstack/solid-store': minor
7+
'@tanstack/vue-store': minor
8+
'@tanstack/store': minor
9+
---
10+
11+
Hooks included in this release:
12+
13+
- useAtom
14+
- useSelector
15+
- useStore (deprecated, replaced by useSelector)
16+
- createStoreContext (provides StoreProvider and useStoreContext for context-based consumption)

.gitignore

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ dist
1919
.env.test.local
2020
.env.production.local
2121
.next
22+
.angular/*
23+
.cache/*
2224

2325
npm-debug.log*
2426
yarn-debug.log*
@@ -41,3 +43,16 @@ stats.html
4143

4244
vite.config.js.timestamp-*
4345
vite.config.ts.timestamp-*
46+
47+
examples/angular/atoms/.angular/cache/*
48+
examples/angular/atoms/.angular/cache/21.2.7/atoms/angular-compiler.db
49+
examples/angular/atoms/.angular/cache/21.2.7/atoms/angular-compiler.db-lock
50+
examples/angular/store-actions/.angular/cache/21.2.7/store-actions/.tsbuildinfo
51+
examples/angular/store-actions/.angular/cache/21.2.7/store-actions/angular-compiler.db
52+
examples/angular/store-actions/.angular/cache/21.2.7/store-actions/angular-compiler.db-lock
53+
examples/angular/store-context/.angular/cache/21.2.7/store-context/.tsbuildinfo
54+
examples/angular/store-context/.angular/cache/21.2.7/store-context/angular-compiler.db
55+
examples/angular/store-context/.angular/cache/21.2.7/store-context/angular-compiler.db-lock
56+
examples/angular/stores/.angular/cache/21.2.7/stores/.tsbuildinfo
57+
examples/angular/stores/.angular/cache/21.2.7/stores/angular-compiler.db
58+
examples/angular/stores/.angular/cache/21.2.7/stores/angular-compiler.db-lock

0 commit comments

Comments
 (0)