⚡ serverside_pivot
Turnkey Analytical Pivot Table & Virtualized Data Grid for React
Dual-Engine Architecture: Zero-Network In-Browser Analytics (DuckDB-WASM & In-Memory) + Scalable Server-Side Pushdown.
serverside_pivot is an enterprise-grade, low-code analytical pivot table and 2D virtualized grid for React. Built on TanStack Table v8, DuckDB-WASM, and Apache ECharts 6, it bridges the gap between lightweight client tables and heavy server-side BI tools.
🚀 Why serverside_pivot?
Unlike traditional grid components that either crash browser memory with large datasets or force you to spend months building custom SQL backends:
- Dual Execution Engine (Hybrid):
- Client-Side Mode (
DuckDB-WASM& In-Memory): Run complete multi-dimensional pivots, $\mathcal{O}(D)$ level-based hierarchy expansions, multi-column sorting, Excel formulas, window functions, and ECharts visualizations 100% inside the browser with ZERO server roundtrips and zero latency. - Server-Side Pushdown Mode: Connect seamlessly to Python backend services (
serverside-pivot) backed by Snowflake, BigQuery, PostgreSQL, ClickHouse, MotherDuck, or DuckDB to query hundreds of millions of rows with bounded 50-row virtual slices.
- Client-Side Mode (
- 2D Virtualization (Row + Column): Smoothly virtualizes both vertical rows (millions of records) and horizontal pivoted columns (1,000+ columns) with a constant < 80 MB client RAM footprint.
- Turnkey BI Analytics: Built-in 23+ chart families (ECharts 2D/3D), inline cell sparklines, heatmaps, Excel-like calculated formulas (
[revenue] - [cost]), window functions (percent_of_grand_total), 11 enterprise themes, and client-side SheetJS XLSX/CSV export.
📦 Installation
npm install serverside_pivot
# or
yarn add serverside_pivot
# or
pnpm add serverside_pivot
Peer Dependencies
npm install react react-dom styled-components
⚡ Quickstart
1. Zero-Backend Client-Side Pivot (DuckDB-WASM / In-Memory)
Feed your JSON records or CSV/Parquet data directly into PivotWorkspace. The internal ClientPivotTransport executes all groupings, multi-column aggregations, and expansions in browser WebAssembly:
import React from 'react';
import { PivotWorkspace, ClientPivotTransport } from 'serverside_pivot/react';
const salesData = [
{ region: 'North America', country: 'USA', rep: 'Alice', year: '2024', revenue: 150000, cost: 95000 },
{ region: 'North America', country: 'USA', rep: 'Bob', year: '2025', revenue: 180000, cost: 110000 },
{ region: 'North America', country: 'Canada', rep: 'Charlie', year: '2024', revenue: 90000, cost: 60000 },
{ region: 'Europe', country: 'Germany', rep: 'David', year: '2024', revenue: 130000, cost: 85000 },
{ region: 'Europe', country: 'France', rep: 'Emma', year: '2025', revenue: 140000, cost: 90000 },
// ... up to 50,000+ rows
];
// Initialize client transport (runs 100% in-browser)
const clientTransport = new ClientPivotTransport({
tableName: 'sales',
data: salesData,
clientEngine: 'auto', // 'auto' (>= 1000 rows activates DuckDB-Wasm), 'duckdb-wasm', or 'memory'
});
export function App() {
return (
<div style={{ height: '800px', width: '100%' }}>
<PivotWorkspace
table="sales"
transport={clientTransport}
rowFields={['region', 'country', 'rep']}
colFields={['year']}
valConfigs={[
{ field: 'revenue', agg: 'sum', format: 'currency', label: 'Revenue ($)' },
{ field: 'cost', agg: 'sum', format: 'currency', label: 'Cost ($)' },
{
field: 'profit',
label: 'Gross Profit',
formula: '[revenue] - [cost]',
format: 'currency',
},
{
field: 'rev_pct',
label: '% Total Revenue',
agg: 'sum',
windowFn: 'percent_of_grand_total',
format: 'percent',
},
]}
showRowTotals={true}
showColTotals={true}
defaultTheme="flash" // 'dark' | 'light' | 'bloomberg_black' | 'flash' | 'material' | ...
/>
</div>
);
}
2. Scalable Server-Side Pushdown Mode
For datasets with millions or billions of rows, connect to any backend implementing the standard V1 runtime protocol:
import React from 'react';
import {
PivotWorkspace,
HttpPivotTransport,
LatestViewportScheduler,
} from 'serverside_pivot/react';
// Wraps HTTP requests with auto-cancellation (latest-viewport-wins)
const transport = new LatestViewportScheduler(
new HttpPivotTransport({
endpoint: '/v1/runtime',
})
);
export function EnterpriseAnalytics() {
return (
<div style={{ height: '100vh', width: '100%' }}>
<PivotWorkspace
table="warehouse_orders"
transport={transport}
rowFields={['department', 'category', 'product']}
colFields={['quarter']}
valConfigs={[
{ field: 'sales_amount', agg: 'sum', format: 'currency' },
{ field: 'order_count', agg: 'count' },
]}
showRowTotals={true}
showColTotals={true}
defaultTheme="dark"
/>
</div>
);
}
✨ Key Enterprise Capabilities
| Feature | Description |
|---|---|
| Dual Execution Engine | Seamlessly toggle between 100% in-browser WebAssembly execution (ClientPivotTransport) and server-side warehouse pushdown (HttpPivotTransport). |
| 2D Virtualization | Constant < 80 MB browser memory whether scrolling through 10,000 rows or 1,000,000,000+ rows with 1,000+ dynamic pivoted columns. |
| $\mathcal{O}(D)$ Level-Based Hierarchy | Multi-level tree group expansions execute one single batched query per hierarchy depth level ($D$) rather than sequential $N$-query waterfalls. |
| Visual Analytics & Charting | Integrated ECharts 6 & ECharts-GL 3D: 23+ chart types across 11 families (Bar, Line, Area, Pie, Radar, Scatter, Waterfall, 3D Bar/Surface) linked to live pivot state. |
| In-Cell Sparklines & Data Bars | High-performance inline SVG sparklines (Line, Area, Bar) and proportional cell data bars rendered directly inside grid cells with zero DOM bloat. |
| Excel AST Formulas & Window Functions | Excel-like calculated measures using [Field] syntax and built-in pivot window functions (percent_of_row, percent_of_col, percent_of_grand_total). |
| 4 Layout Modes | Multidimensional Pivot (pivot), Parent-Child Tree (tree), Flat Record Grid (table), and Financial P&L Report Mode (report). |
| Client SheetJS & Clipboard | Instant client-side Excel XLSX and CSV streaming export with merged headers and formatting preserved. RFC-compliant HTML/TSV clipboard copy. |
| 11 Enterprise Themes | Complete theme system: light, dark, flash, material, balham, bloomberg, bloomberg_black, strata, crystal, alabaster, satin with full --sp-* CSS variables. |
🌐 Multi-Framework Ecosystem
serverside_pivot is part of the serverside-pivot ecosystem:
- Standalone React:
serverside_pivot(this package) - Python Plotly Dash:
pip install serverside-pivot - Streamlit:
pip install "serverside-pivot[streamlit]" - Backend Pushdown: Powered by DuckDB, PyArrow, and Ibis (Snowflake, BigQuery, Postgres, ClickHouse, MotherDuck, Databricks, Trino)
For comprehensive documentation, live Python/Dash showcases, and interactive examples, visit the GitHub Repository.
Cell editing and edit transactions are not a supported public capability in this release. Legacy edit-related Dash inputs are accepted as no-ops only for layout compatibility.
📄 License
Distributed under the MIT License.
Metadata
Release files for serverside-pivot 0.0.95
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| serverside_pivot-0.0.95-py3-none-any.whl | Python 3 | none | any | Details for serverside_pivot-0.0.95-py3-none-any.whl |
Release files / serverside_pivot-0.0.95-py3-none-any.whl
| Download URL | serverside_pivot-0.0.95-py3-none-any.whl |
|---|---|
| Size | 2.4 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e9e8b4c27b07359948f3c43f3944928c8b7e50b65774fbe4324493d2c305f3c5
|
|
BLAKE2b-256 checksum How to use checksums |
d49b20ec067e0d7845c83c5bc7d72c52ab6e03e90b9a0d13a3dcde4c3d296f64
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 14, 2026.
Transparency logSecurity for serverside-pivot 0.0.95
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
1 file in this release has been uploaded with provenance metadata.
Attestation for serverside_pivot-0.0.95-py3-none-any.whl
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Nov 14, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.