@octanejs/tanstack-store 0.0.47 → 0.0.48

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@octanejs/tanstack-store",
3
- "version": "0.0.47",
3
+ "version": "0.0.48",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "engines": {
@@ -48,7 +48,7 @@
48
48
  "@testing-library/jest-dom": "^6.9.1",
49
49
  "@testing-library/react": "16.3.1",
50
50
  "@testing-library/user-event": "^14.6.1",
51
- "@tsrx/react": "^0.2.63",
51
+ "@tsrx/react": "^0.2.67",
52
52
  "@types/react": "19.2.7",
53
53
  "@types/react-dom": "19.2.3",
54
54
  "@types/use-sync-external-store": "^1.5.0",
@@ -58,7 +58,7 @@
58
58
  "use-sync-external-store": "1.6.0",
59
59
  "vitest": "^4.1.10",
60
60
  "@octanejs/testing-library": "0.1.50",
61
- "octane": "0.2.3"
61
+ "octane": "0.2.4"
62
62
  },
63
63
  "scripts": {
64
64
  "test": "vitest run",
@@ -3,7 +3,12 @@ import { splitSlot, subSlot } from './internal';
3
3
  import { useSyncExternalStoreWithSelector } from './useSyncExternalStoreWithSelector';
4
4
 
5
5
  export interface UseSelectorOptions<TSelected> {
6
- compare?: (a: TSelected, b: TSelected) => boolean;
6
+ // Written as an optional property that also admits `undefined`, because this
7
+ // package publishes source and the consumer's compiler options apply to it.
8
+ // Under `exactOptionalPropertyTypes` a bare `compare?:` would reject both an
9
+ // options object forwarded from another optional value and this package's own
10
+ // `useStore` bridge, which always passes the key through.
11
+ compare?: ((a: TSelected, b: TSelected) => boolean) | undefined;
7
12
  }
8
13
 
9
14
  type SyncExternalStoreSubscribe = Parameters<typeof useSyncExternalStoreWithSelector>[0];