react-data-grid-lite
Version:
A fast, lightweight, and customizable Data Grid for React.
115 lines (85 loc) โข 4.04 kB
Markdown
[](https://www.npmjs.com/package/react-data-grid-lite)


[](https://github.com/ricky-sharma/react-data-grid-lite/archive/refs/heads/master.zip)


[](https://ricky-sharma.github.io/react-data-grid-lite/)
A lightweight and customizable React data grid component designed for high performance and ease of use. The DataGrid component is a highly customizable, feature-rich table component designed to display tabular data in a React application. It is intended for use cases where large datasets need to be presented with advanced features such as pagination, sorting, searching, row interactions, and more.
โ
**Key Features**
โก **Lightweight** โ Small bundle size, fast loading
๐ฆ **API-ready** โ Works with any JSON API
๐ ๏ธ **Dynamic columns** โ Auto-adapts to data schema
๐ **Search & aliases** โ Fast filtering, custom labels
๐ **Fixed columns** โ Lock columns during scroll
๐ **Resizable columns** โ User can drag to resize
๐ฑ **Responsive layout** โ Adapts to all screen sizes
๐งพ **CSV export** โ Download full data grid
โ๏ธ **Row actions** โ Built-in edit/delete hooks
๐งฉ **Merged columns** โ Combine multiple fields
๐ **Analytics events** โ Track user interactions
๐จ Theming โ Pre-built themes & easy customization
๐งฉ Actions align โ Fix column left or right via prop
๐งช Fully tested โ Robust unit coverage and fixes
<br><br>
<p align="center">
<img src="https://github.com/user-attachments/assets/bf6ef7d8-1475-4554-8177-de1f794edb4b" alt="react-data-grid-lite 19 July -2" width="95%" />
</p>
<br><br>
```bash
npm install react-data-grid-lite
```
or
```bash
yarn add react-data-grid-lite
```
<br><br>
```jsx
import React from 'react';
import DataGrid from 'react-data-grid-lite';
const columns = [
{ name: 'id', width:'50px' },
{ name: 'name', alias:'Full Name' },
{ name: 'age' }
];
const rows = [
{ id: 1, name: 'John Doe', age: 28 },
{ id: 2, name: 'Jane Smith', age: 34 },
{ id: 3, name: 'Sam Johnson', age: 22 }
];
function App() {
return (
<div>
<h1>Data Grid Example</h1>
<DataGrid
columns={columns}
data={rows}
/>
</div>
);
}
export default App;
```
<br><br>
The `react-data-grid-lite` library is compatible with the following versions of React:
| **React Version** | **Compatibility** |
| ----------------- | ------------------ |
| **React 19+** | โ
Fully Compatible |
| **React 18+** | โ
Fully Compatible |
| **React 17+** | โ
Fully Compatible |
<br><br>
- [API Reference](https://github.com/ricky-sharma/react-data-grid-lite/blob/master/docs/api.md)
<br><br>
Feel free to fork the repository and experiment with the grid's behavior for concatenating columns. Let me know if you'd like any further adjustments or clarification! Happy coding! ๐
<br><br>
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
<br><br>
Reach out via [LinkedIn](https://www.linkedin.com/in/vinay-sharma-2022354) or check out my projects on [GitHub](https://github.com/ricky-sharma).