elixcee-wasm 0.1.0

wasm-bindgen bridge for bounded XLSX reading, formula calculation, diagnostics, and stateful workbook editing
Documentation
  • Coverage
  • 27.78%
    5 out of 18 items documented0 out of 17 items with examples
  • Size
  • Source code size: 96.56 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 496.2 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 15s Average build duration of successful builds.
  • all releases: 15s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • Homepage
  • kent-tokyo/elixcee
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • kent-tokyo

elixcee-wasm

elixcee-wasm is the Rust/WASM bridge for bounded, headless workbook operations. It is designed for browser and Node.js integrations that need the same Rust reader and formula/diagnostic behavior without installing Excel.

This is the reusable runtime behind the project's browser Playground. The Playground also contains a separate JavaScript XLSX writer and an Excel-like UI; those are integration layers, not part of this crate.

Install

Add the crate to a Rust/WASM application:

[dependencies]
elixcee-wasm = "0.1"

For a browser package, build the bindings with wasm-pack:

wasm-pack build --target web

Current API

The wasm-bindgen exports provide:

  • readWorkbook(bytes) for bounded XLSX/XLSM/ODS reading; simple workbook defined names are returned as Workbook.Names with their Name, Ref, and optional zero-based local Sheet scope;
  • calculateWorkbook(bytes) for supported formula recalculation;
  • diagnoseWorkbook(bytes) for deterministic workbook diagnostics;
  • WorkbookEditor for bounded typed cell edits, recalculation, snapshots, transactions, and undo/redo.

Coordinates exposed by the editor are 1-based, matching Excel and VBA. Malformed, oversized, or otherwise unsafe input is rejected by the shared Rust reader limits. The editor also validates worksheet names and cell bounds.

Minimal browser integration

The crate is intended to be consumed through the wasm-bindgen bindings it generates. The generated package exposes the same API in Node and browsers:

import init, { WorkbookEditor, readWorkbook } from "elixcee-wasm";

await init();
const summary = JSON.parse(readWorkbook(workbookBytes));
const editor = new WorkbookEditor(workbookBytes);
editor.setNumber("Sheet1", 1, 1, 42);
const calculated = JSON.parse(editor.recalculate());

readWorkbook and WorkbookEditor return JSON-shaped workbook data so an application can provide its own grid, clipboard, accessibility model, and serialization policy. The crate deliberately does not prescribe an Excel-like UI. For a complete example, see the repository's Playground and its source.

Scope boundary

This crate is a reusable runtime bridge, not an Excel UI and not a complete XLSX writer. It is the crate-level distribution target for the Playground's reusable browser runtime; the Excel-like screen itself remains a separate static web application. In other words, the Playground's read/calculation/diagnostics/ bounded typed-edit capability is reusable as a crate, while its grid and JavaScript XLSX writer are separate integration layers. The current JavaScript package owns XLSX serialization and the Playground owns the spreadsheet UI. The Playground is an integration example, not part of this crate's API. It does not execute arbitrary VBA, access the filesystem, network, COM, Shell, MsgBox, or UserForm. Existing VBA project bytes may be preserved by supported JavaScript/native round-trip paths, but preservation is not arbitrary macro execution.

Use the repository's support contract and XLSX architecture for the exact compatibility and safety boundaries. The crate is prepared for publication after the matching native elixcee release is available on crates.io. Its current checkout may use a newer native API than the last published elixcee version, so the release workflow publishes the native crate first and waits for index visibility before publishing this bridge. Publication remains an explicit release operation.

Building

cargo check -p elixcee-wasm --target wasm32-unknown-unknown
wasm-pack build crates/elixcee-wasm --target web

The repository build scripts inline the generated WASM into the browser and Node package entry points. Consumers should use those package artifacts until the crate's JS API and generated package layout are declared stable.

See the MIT license.