virtua 0.2.4 → 0.4.0

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.
@@ -0,0 +1,2 @@
1
+ import { VirtualStore } from "../core/store";
2
+ export declare const useStore: <T>(store: VirtualStore, getSnapShot: () => T, shouldGetLatest?: boolean) => T;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "virtua",
3
- "version": "0.2.4",
3
+ "version": "0.4.0",
4
4
  "description": "A zero-config, fast and small (~3kB) virtual list and grid component for React.",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/index.mjs",
@@ -21,9 +21,6 @@
21
21
  "typedoc": "typedoc",
22
22
  "prepublishOnly": "npm run typedoc && rimraf lib && npm run build"
23
23
  },
24
- "dependencies": {
25
- "use-sync-external-store": "^1.2.0"
26
- },
27
24
  "devDependencies": {
28
25
  "@babel/plugin-transform-react-pure-annotations": "7.18.6",
29
26
  "@dnd-kit/core": "6.0.8",
@@ -35,17 +32,16 @@
35
32
  "@playwright/test": "^1.34.3",
36
33
  "@rollup/plugin-babel": "6.0.3",
37
34
  "@rollup/plugin-terser": "0.4.3",
38
- "@rollup/plugin-typescript": "11.1.1",
35
+ "@rollup/plugin-typescript": "11.1.2",
39
36
  "@storybook/addon-docs": "7.0.18",
40
37
  "@storybook/react": "7.0.18",
41
38
  "@storybook/react-vite": "^7.0.18",
42
39
  "@storybook/test-runner": "0.10.0",
43
40
  "@tanstack/react-virtual": "3.0.0-alpha.0",
44
41
  "@testing-library/react": "14.0.0",
45
- "@types/react": "18.2.7",
42
+ "@types/react": "18.2.14",
46
43
  "@types/react-virtualized": "9.21.22",
47
44
  "@types/react-window": "1.8.5",
48
- "@types/use-sync-external-store": "0.0.3",
49
45
  "@typescript-eslint/parser": "5.59.2",
50
46
  "concurrently": "8.0.1",
51
47
  "eslint": "8.42.0",
@@ -58,25 +54,27 @@
58
54
  "react-cool-virtual": "0.7.0",
59
55
  "react-dom": "18.2.0",
60
56
  "react-is": "18.2.0",
61
- "react-merge-refs": "2.0.1",
57
+ "react-merge-refs": "2.0.2",
62
58
  "react-pull-to-refresh": "2.0.1",
63
59
  "react-select": "5.7.3",
64
60
  "react-virtualized": "9.22.5",
65
- "react-virtuoso": "4.3.5",
61
+ "react-virtuoso": "4.3.11",
66
62
  "react-window": "1.8.9",
67
63
  "rimraf": "5.0.0",
68
64
  "rollup": "3.23.0",
65
+ "rollup-plugin-banner2": "1.2.2",
69
66
  "storybook": "^7.0.18",
70
67
  "ts-jest": "29.1.0",
71
68
  "typedoc": "0.24.7",
72
69
  "typedoc-plugin-markdown": "3.15.3",
73
70
  "typescript": "5.1.3",
74
- "virtua": "^0.2.3",
71
+ "virtua": "^0.3.0",
75
72
  "vite": "4.3.9",
76
73
  "wait-on": "7.0.1"
77
74
  },
78
75
  "peerDependencies": {
79
- "react": ">=16.14.0"
76
+ "react": ">=16.14.0",
77
+ "react-dom": ">=16.14.0"
80
78
  },
81
79
  "repository": {
82
80
  "type": "git",
@@ -1,2 +0,0 @@
1
- /// <reference types="react" />
2
- export type WindowComponentAttributes = Pick<React.HTMLAttributes<HTMLElement>, "className" | "style" | "id" | "role" | "tabIndex"> & React.AriaAttributes;
@@ -1 +0,0 @@
1
- export declare const useSyncExternalStore: <T>(subscibe: (onStoreChange: () => void) => () => void, getSnapShot: () => T) => T;