npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@uipath/ui-widgets-datatable

v1.0.0-beta.1

Published

A simple React datatable component

Readme

@uipath/ui-widgets-datatable

A powerful and flexible React datatable component built with ag-Grid, designed for UiPath entity management.

Features

  • 🔄 CRUD Operations: Full support for Create, Read, Update, Delete operations
  • 📊 Master-Detail View: Group data by foreign key relationships
  • ✏️ Inline Editing: Edit cells directly with support for different field types
  • 🔍 Filtering & Sorting: Built-in filtering and sorting capabilities
  • 📄 Pagination: Efficient data pagination
  • 🎨 Customizable: Flexible column configuration and styling
  • 🔗 Foreign Key Support: Special handling for relationship fields
  • 📝 Diff Viewer: Review changes before committing
  • Fully Tested: Comprehensive unit test coverage

Installation

npm install @uipath/ui-widgets-datatable

Usage

import { DataTable } from "@uipath/ui-widgets-datatable";
import { UiPath } from "@uipath/uipath-typescript/entities";

function App() {
  const sdk = new UiPath({
    /* config */
  });

  return <DataTable sdk={sdk} entityId="your-entity-id" pageSize={50} />;
}

Props

| Prop | Type | Required | Default | Description | | --------------- | ------------------------ | -------- | ------- | --------------------------- | | sdk | UiPath | Yes | - | UiPath SDK instance | | entityId | string | Yes | - | ID of the entity to display | | className | string | No | '' | Additional CSS class name | | pageSize | number | No | 50 | Number of rows per page | | columnConfig | Record<string, ColDef> | No | - | Custom column configuration | | rowClassRules | RowClassRules | No | - | Custom row styling rules |

Features in Detail

CRUD Operations

Create

  • Click "Add Row" to add a new row
  • Fill in the data
  • Click "Insert Records" to save

Read

  • Data is automatically loaded on mount
  • Click "Refresh" to reload data

Update

  • Click any cell to edit (when not in master-detail mode)
  • Changes are tracked automatically
  • Click "Show Diff" to review changes
  • Click "Commit Changes" to save

Delete

  • Select rows using checkboxes
  • Click "Delete Records"
  • Confirm deletion

Master-Detail View

Group records by foreign key relationships:

  1. Select a groupable column from the "Group by" dropdown
  2. Click the expand button to view related records
  3. Related records are displayed in a nested grid

Field Types

The datatable automatically handles different field types:

  • Text: Standard text input
  • Number: Numeric input
  • Date: Date picker
  • Foreign Key: Dropdown with reference entity records

Custom Column Configuration

<DataTable
  sdk={sdk}
  entityId="entity-id"
  columnConfig={{
    "Column Name": {
      width: 200,
      editable: false,
      cellStyle: { color: "blue" },
    },
  }}
/>

Custom Row Styling

<DataTable
  sdk={sdk}
  entityId="entity-id"
  rowClassRules={{
    "row-highlight": (params) => params.data.status === "Active",
    "row-disabled": (params) => params.data.status === "Inactive",
  }}
/>

Development

Running Tests

# Run all tests
npm test

# Run tests in watch mode
npm test -- --watch

# Run tests with UI
npm run test:ui

# Generate coverage report
npm run test:coverage

Building

npm run build

Architecture

Components

  • DataTable: Main component that orchestrates the entire datatable
  • Toolbar: Action buttons and controls
  • DiffDialog: Modal for reviewing changes
  • DetailPanel: Nested grid for master-detail view
  • CellWithExpandButton: Custom cell renderer with expand/collapse
  • RefFieldCellEditor: Custom editor for foreign key fields

Hooks

  • useEntityData: Manages entity data fetching and column definitions
  • useRowEditing: Handles row editing state and operations
  • useEntityRecordsCache: Caches entity records for performance

Utils

  • dataUtils: Data manipulation utilities (deepClone, getDiffData, hasRowChanges)
  • fieldUtils: Field-related utilities (getFieldValue, createValueSetter, createCellEditorSelector)

Testing

This package includes comprehensive unit tests following best practices:

  • Utils: 100% coverage of utility functions
  • Hooks: Full coverage of custom hooks with various scenarios
  • Components: Component rendering, user interactions, and edge cases

See TEST_GUIDE.md for detailed testing guidelines.

Browser Support

  • Chrome (latest)
  • Firefox (latest)
  • Safari (latest)
  • Edge (latest)

License

MIT

Contributing

Contributions are welcome! Please follow the testing guidelines and ensure all tests pass before submitting a PR.