@libraz/formulon-cell-vue

Vue 3 component + composables for @libraz/formulon-cell.
2,307
Install
npm install @libraz/formulon-cell-vue
Latest Version:0.10.0
Vue:3
License:Apache-2.0
Last Updated:Oct 19, 2026
Links: GitHub  ·  npm
Maintainer: libraz

@libraz/formulon-cell-vue

CI npm npm — core npm — react License Vue Docs Demo

A working spreadsheet in a Vue app. <Spreadsheet> and SpreadsheetToolbar wrap @libraz/formulon-cell, a canvas-rendered grid with desktop-spreadsheet chrome over the formulon WASM calc engine. Prop changes go through the core imperative API, so the canvas is never re-mounted and selection, focus, and event subscriptions survive.

Try it in the live demo.

The grid, ribbon, menus, commands, and dialogs all live in core; this package only binds them to Vue.

Install

npm install @libraz/formulon-cell-vue @libraz/formulon-cell vue zustand

Bundler settings are in the project README.

Quick start

<script setup lang="ts">
import { Spreadsheet, presets, type SpreadsheetInstance } from '@libraz/formulon-cell-vue';
import '@libraz/formulon-cell/styles.css';

const ready = (instance: SpreadsheetInstance) => {
  console.log('mounted', instance.workbook.version);
};
</script>

<template>
  <Spreadsheet
    :features="presets.full()"
    locale="en"
    style="width: 100%; height: 100vh"
    @ready="ready"
  />
</template>

Composables

const sheetRef = ref<SpreadsheetExposed | null>(null);
const instance = computed(() => sheetRef.value?.instance.value ?? null);
const selection = useSelection(instance);
const { locale, strings } = useI18n(instance);
composable description
useSelection(instance) the active selection
useSpreadsheet(instance, selector, fallback) any slice of the store state
useI18n(instance) current locale and strings, updated on runtime swaps
useSpreadsheetEvent(instance, event, handler) subscribe to cellChange, selectionChange, recalc, …

Ribbon toolbar

SpreadsheetToolbar ships as an SFC subpath so it compiles with your own Vue pipeline. It adapts core Spreadsheet.mountToolbar; pass dropdownActions to replace individual dropdown handlers without forking the ribbon.

<script setup lang="ts">
import SpreadsheetToolbar from '@libraz/formulon-cell-vue/toolbar.vue';
import '@libraz/formulon-cell-vue/toolbar.css';
</script>

<template>
  <SpreadsheetToolbar :instance="instance" :active-tab="tab" locale="en" @tab-change="tab = $event" />
</template>

Restricted embedding

ui, policy, viewport, context-menu, overlays, and toolbar props apply at runtime without re-mounting. fixedFormPolicy and viewerPolicy are re-exported, and successful batch updates are emitted as change-batch.

<Spreadsheet
  :ui="{ profile: 'embedded' }"
  :policy="fixedFormPolicy([{ sheet: 0, r0: 1, c0: 1, r1: 9, c1: 2 }])"
  @change-batch="save"
/>

See Embedding and use cases for viewport limits, context-menu composition, and host updates.

Documentation

License

Apache-2.0

Related Packages

@vueye-table/vue

Vue composables that bind the vueye-table engine to reactive state.

2,828 111
@vueye-table/headless

Unstyled, accessible Vue components for vueye-table: tables, controls, and sprea...

2,762 111
@vueye-table/styled

Styled, themeable Vue components for vueye-table, built on the headless layer.

2,606 111

Version History

Version Released Vue License
0.10.0 ^3.3 Apache-2.0
0.9.1 ^3.3 Apache-2.0
0.9.0 ^3.3 Apache-2.0
0.8.0 ^3.3 Apache-2.0
0.7.0 ^3.3 Apache-2.0