Vue pivot table

Pivot mode with row and grand totals for Vue, inside the same grid your users already know.

Grid Pro

v1 launch

$349

Per developer, paid once, lifetime updates

A working starting point

npm install @birchui/vue @birchui/core @birchui/grid-pro
Show Pivot-table.vue
Pivot-table.vue
<script setup>
import { shallowRef } from 'vue';
import { BirchGrid } from '@birchui/vue';
import { PivotModule } from '@birchui/grid-pro';

const sales = [
  { id: 'SO-10421', region: 'Europe', country: 'France', year: 2026, revenue: 1890.5 },
  { id: 'SO-10422', region: 'Europe', country: 'Germany', year: 2025, revenue: 459 },
  { id: 'SO-10423', region: 'North America', country: 'Canada', year: 2026, revenue: 712.25 },
];

const columns = [
  { field: 'region', header: 'Region' },
  { field: 'year', header: 'Year', type: 'number' },
  { field: 'revenue', header: 'Revenue', type: 'number' },
];
const modules = [PivotModule];
const pivot = {
  enabled: true,
  rows: ['region'],
  columns: ['year'],
  values: [{ colId: 'revenue', aggFunc: 'sum' }],
  totals: true,
};

const height = shallowRef('520px');
</script>

<template>
  <BirchGrid
    :style="{ height }"
    :license-key="'LQ1.your-key'"
    :modules="modules"
    :columns="columns"
    :rows="sales"
    :pivot="pivot"
  />
</template>

Measured in Chrome: pivoting 100,000 rows takes 52–93 ms. For an end-user report builder, see Pivot Studio.

How it fits Vue

Pivot mode turns rows into columns such as 2026 › Q1 › Revenue, with row and grand totals and sorting by any pivot column. It is part of Grid Pro, so a Vue team that needs pivoting buys one product, not an enterprise suite.

The Vue adapter wraps the pivot table engine in a render-function component. Options arrive as an options object, as attributes, or both, and kebab-case attributes become camelCase keys.

Hold large arrays in shallowRef or markRaw. A deep ref would wrap every record in a proxy the widget never needs. With vue/server-renderer the component renders only its container; the widget is created in onMounted, so Nuxt pages hydrate cleanly.

Questions

Can Vue users drag fields to build their own pivot?

Grid Pro pivots from options you set in code. Pivot Studio adds a drag-and-drop field list, drill-through and saved reports.

Can I export the pivot to Excel?

Yes. The Excel module exports the current view, pivot columns and totals included, as a styled xlsx file.

Do I need the SFC compiler to use the Vue pivot table?

No. The components are render functions, so they work in single-file components, JSX or plain h() calls.

How are events named in Vue?

Every widget event is emitted in kebab-case, such as @selection-changed or @event-drop, with the event object as payload.