@simplestack/store 0.6.0 → 0.6.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +9 -5
  2. package/package.json +6 -1
package/README.md CHANGED
@@ -1,6 +1,10 @@
1
1
  # Simple Store
2
2
 
3
- A simple, `select`-xcellent state management library with the power of Jotai and Zustand combined.
3
+ A simple, `select`-xcellent state management library for React.
4
+
5
+ The goal: make a storage solution as powerful as Zustand or Redux, without complicated functions to set and select state.
6
+
7
+ Here's an overview of how stores are created, and how you can operate on parts of a store using `.select()`:
4
8
 
5
9
  ```tsx
6
10
  import { store } from "@simplestack/store";
@@ -16,10 +20,6 @@ const documentStore = store({
16
20
  },
17
21
  });
18
22
 
19
- // Select parts of a store to listen to individually
20
- const titleStore = documentStore.select("title");
21
- const tagsStore = documentStore.select("meta").select("tags");
22
-
23
23
  function Document() {
24
24
  // Update your UI with the store's current state
25
25
  const { title, tags } = useStoreValue(documentStore);
@@ -30,6 +30,10 @@ function Document() {
30
30
  );
31
31
  }
32
32
 
33
+ // Or, select parts of a store to listen to individually
34
+ const titleStore = documentStore.select("title");
35
+ const tagsStore = documentStore.select("meta").select("tags");
36
+
33
37
  function Title() {
34
38
  // And scope updates with selected stores for fine-grained control
35
39
  const title = useStoreValue(titleStore);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@simplestack/store",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "description": "A simple storage solution for React",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -23,6 +23,11 @@
23
23
  ],
24
24
  "author": "bholmesdev",
25
25
  "license": "MIT",
26
+ "homepage": "https://simple-stack.dev/store",
27
+ "repository": {
28
+ "type": "git",
29
+ "url": "https://github.com/bholmesdev/simplestack-store.git"
30
+ },
26
31
  "devDependencies": {
27
32
  "@biomejs/biome": "2.2.2",
28
33
  "@types/react": "^19.1.12",