Skip to main content

Overview

OGrid is a lightweight, open-source data grid library that delivers spreadsheet-grade features without the enterprise paywall. It ships with React, Angular, and Vue adapters -- each with multiple UI library implementations -- plus a vanilla JS package, all powered by a shared TypeScript core.

Why OGrid?

Most production-grade React data grids fall into one of two camps: free but limited, or feature-rich but locked behind expensive licenses. OGrid bridges that gap.

  • Free and MIT-licensed. Every feature is included. No enterprise tier, no feature gating.
  • 20+ built-in features. Sorting, filtering, pagination, cell editing, clipboard, undo/redo, fill handle, row selection, cell range selection, column pinning, column groups, CSV export, context menu, keyboard navigation, status bar, and more.
  • Multiple frameworks. React, Angular, and Vue adapters with UI library choices for each -- switch later with zero logic changes.
  • TypeScript-first. Full strict-mode TypeScript with exported types for every prop, event, and API method.
  • Lightweight. The Radix package has no heavy framework dependency. Fluent and Material packages use their respective component libraries as peer dependencies.

Architecture

OGrid is built on a 3-layer architecture: a pure TypeScript core, framework adapter layers (React hooks, Angular services, Vue composables), and thin UI shells. No duplicated logic, no drift.

@alaarab/ogrid-react-radix
Radix Primitives
@alaarab/ogrid-react-fluent
Fluent UI v9
@alaarab/ogrid-react-material
Material UI v7
@alaarab/ogrid-angular-material
Angular Material v21
@alaarab/ogrid-angular-primeng
PrimeNG v21
@alaarab/ogrid-vue-vuetify
Vuetify 3
@alaarab/ogrid-vue-primevue
PrimeVue 4
@alaarab/ogrid-react
Hooks · Headless Components
@alaarab/ogrid-angular
Services · Signals · Components
@alaarab/ogrid-vue
Composables · Utilities
@alaarab/ogrid-js
Vanilla JS Grid
@alaarab/ogrid-core
Types · Algorithms · Utilities (zero deps)
React
Angular
Vue
Vanilla JS
Core

Core Layer — @alaarab/ogrid-core

Pure TypeScript with zero dependencies. Provides the type system (IOGridProps, IColumnDef, IOGridApi, FilterValue, etc.) and shared algorithms (getCellValue, buildHeaderRows, parseValue, normalizeSelectionRange, etc.) used by both the React and JS packages.

Framework Adapter Layers

Each framework adapter translates Core's algorithms into idiomatic framework patterns — React hooks, Angular services with signals, or Vue composables with refs.

React@alaarab/ogrid-react

DomainHooks
OrchestrationuseOGrid · useDataGridState
Cell EditinguseCellEditing · useInlineCellEditorState · useRichSelectState
SelectionuseCellSelection · useRowSelection · useActiveCell
NavigationuseKeyboardNavigation (arrow keys, Tab, Enter, Ctrl+Arrow)
ClipboarduseClipboard · useFillHandle · useUndoRedo
LayoutuseColumnResize · useSideBarState · useColumnChooserState
FilteringuseColumnHeaderFilterState · useFilterOptions

Angular@alaarab/ogrid-angular

Angular v21 services using signals (signal(), computed(), effect()). Standalone components with inline templates. Zone-less by default.

ServiceEquivalent
OGridServiceuseOGrid — pagination, sorting, filtering, visibility, editing
DataGridStateServiceuseDataGridState — layout, selection, editing, interaction

Vue@alaarab/ogrid-vue

Vue 3 Composition API composables using ref(), computed(), watch().

ComposableEquivalent
useOGridPagination, sorting, filtering, column visibility
useDataGridStateLayout, cell selection, editing, clipboard, keyboard nav
20+ feature composablesuseCellEditing, useCellSelection, useClipboard, etc.

UI Layer — Pick Your Framework

Each UI package is a thin shell (~1,500 lines) that calls the same core logic and renders into native components:

PackageBuilt onBest for
@alaarab/ogrid-react-radixRadix primitivesLightweight apps, custom design systems
@alaarab/ogrid-react-fluentFluent UI v9Microsoft 365, SharePoint, Teams apps
@alaarab/ogrid-react-materialMUI v7Material Design apps, dashboards
@alaarab/ogrid-angular-materialAngular Material v21Angular + Material Design
@alaarab/ogrid-angular-primengPrimeNG v21Angular + PrimeNG ecosystem
@alaarab/ogrid-vue-vuetifyVuetify 3Vue + Material Design
@alaarab/ogrid-vue-primevuePrimeVue 4Vue + PrimeVue ecosystem

All packages within a framework export the same OGrid component with the same props. Switching UI libraries is a one-line import change — your column definitions, event handlers, data sources, and API calls stay identical.

Why This Matters

  • Write once, render anywhere. A bug fix or feature in core lands across all frameworks instantly.
  • Zero lock-in. Migrate between React, Angular, and Vue without rewriting business logic.
  • Guaranteed parity. Shared core ensures all packages behave identically.
  • Small surface area. No duplicated state logic to drift out of sync.

Packages

PackagenpmDescription
@alaarab/ogrid-corenpmPure TS types, algorithms, utilities (zero deps)
React
@alaarab/ogrid-reactnpmReact hooks, headless components, utilities
@alaarab/ogrid-react-radixnpmRadix UI implementation (default, lightweight)
@alaarab/ogrid-react-fluentnpmFluent UI v9 implementation
@alaarab/ogrid-react-materialnpmMaterial UI v7 implementation
Angular
@alaarab/ogrid-angularnpmAngular v21 services with signals
@alaarab/ogrid-angular-materialnpmAngular Material v21 implementation
@alaarab/ogrid-angular-primengnpmPrimeNG v21 implementation
Vue
@alaarab/ogrid-vuenpmVue 3 composables with Composition API
@alaarab/ogrid-vue-vuetifynpmVuetify 3 implementation
@alaarab/ogrid-vue-primevuenpmPrimeVue 4 implementation
Other
@alaarab/ogrid-jsnpmVanilla JS data grid (no framework)

Feature Highlights

FeatureDescription
SortingSingle-column sort with ascending/descending toggle
FilteringText, multi-select, and people filters per column
PaginationClient-side or server-side with configurable page sizes
Cell EditingInline text, select, checkbox, and rich select editors
Cell SelectionSpreadsheet-style range selection with drag support
ClipboardCopy/paste with multi-cell support (Ctrl+C / Ctrl+V)
Fill HandleDrag to fill cells (like Excel)
Undo/RedoFull undo/redo stack for cell edits
Row SelectionSingle or multiple row selection with checkbox column
Column PinningPin columns to left or right edge
Column GroupsMulti-row grouped column headers
Column ChooserShow/hide columns with a dropdown
Context MenuRight-click menu with copy, paste, undo, and export
CSV ExportOne-click export to CSV
Keyboard NavigationArrow keys, Tab, Enter, Escape for full keyboard control
Status BarRow count, filtered count, selected count, and aggregations
Server-Side DataIDataSource interface for server-side pagination and filtering
Grid APIImperative IOGridApi ref for programmatic control
Column ResizeDrag column borders to resize
ThemingInherits your framework's theme automatically

Coming from AG Grid?

OGrid is designed as a drop-in replacement for AG Grid with a simpler, more React-idiomatic API. If you are migrating from AG Grid, see the Migration Guide.

Next Steps