@tipolox/litgrid-react 1.0.0 → 1.0.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 +41 -0
  2. package/package.json +2 -2
package/README.md ADDED
@@ -0,0 +1,41 @@
1
+ # @tipolox/litgrid-react
2
+
3
+ React integration for LitGrid's `yc-grid` Web Component. The `DataGrid` component provides React props and an imperative ref API. The Web Component dependency is included.
4
+
5
+ ## Install
6
+
7
+ ```bash
8
+ npm install @tipolox/litgrid-react
9
+ ```
10
+
11
+ Requires React and React DOM matching the package's peer dependency range: `^19.2.5`. Use a modern browser with native Web Component support and a bundler that supports ECMAScript modules.
12
+
13
+ ## Quick start
14
+
15
+ ```tsx
16
+ import { DataGrid } from '@tipolox/litgrid-react'
17
+
18
+ const data = [
19
+ { id: 1, name: 'Ada' },
20
+ { id: 2, name: 'Grace' }
21
+ ]
22
+ const columns = [
23
+ { key: 'id', header: 'ID', width: 80 },
24
+ { key: 'name', header: 'Name', width: 180 }
25
+ ]
26
+
27
+ export function UsersGrid() {
28
+ return <DataGrid data={data} columns={columns} height={400} />
29
+ }
30
+ ```
31
+
32
+ Render `UsersGrid` in your React application. `height` defines the viewport used for row virtualization.
33
+
34
+ ## Resources
35
+
36
+ - [Live demo](https://tipolox.com/litgrid/demo)
37
+ - [Repository](https://github.com/tipolox/litgrid)
38
+ - [React guide](https://github.com/tipolox/litgrid/blob/main/docs/react-guide.md)
39
+ - [API reference](https://github.com/tipolox/litgrid/blob/main/docs/api-reference.md)
40
+
41
+ Licensed under the [MIT License](https://github.com/tipolox/litgrid/blob/main/LICENSE).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tipolox/litgrid-react",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "React integration for LitGrid.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -38,7 +38,7 @@
38
38
  "access": "public"
39
39
  },
40
40
  "dependencies": {
41
- "@tipolox/litgrid-web": "^1.0.0"
41
+ "@tipolox/litgrid-web": "^1.0.2"
42
42
  },
43
43
  "peerDependencies": {
44
44
  "react": "^19.2.5",