-
Notifications
You must be signed in to change notification settings - Fork 1
Changelog
ABCrimson edited this page Mar 2, 2026
·
18 revisions
Browser-first release with IIFE bundle, CDN distribution, Web Worker support, and framework examples. 419 tests (171 Rust + 248 TypeScript).
-
IIFE build — self-contained
modern-xlsx.min.js(~29 KB) exposingwindow.ModernXlsx - CDN distribution — available on jsDelivr and unpkg, no bundler required
-
detectWasmUrl()— auto-detection of WASM binary URL fromdocument.currentScript.src -
initWasmSync(module)— synchronous WASM initialization from pre-loaded buffer -
ensureReady()— lazy auto-initialization on first use (cached Promise pattern) -
Source maps —
.mapfiles generated for all build outputs (ESM, IIFE, Worker)
-
createXlsxWorker()— off-thread XLSX read/write via Web Worker message passing -
modern-xlsx.worker.js— dedicated worker script with auto WASM init -
Transferable buffers — zero-copy transfer of
Uint8Arrayresults back to main thread
- tsdown 3-build config — ESM (primary), IIFE (browser), Worker (off-thread)
-
Package exports —
"."(ESM),"./browser"(IIFE),"./worker"(Worker script) -
browser/unpkg/jsdelivrfields in package.json for CDN auto-resolution
-
Interactive browser playground at
docs/site/playground.html - 6 built-in examples: Hello World, Styled Workbook, Read & Inspect, Batch Data, JSON to Sheet, Formulas & Dates
- Live WASM status indicator, Ctrl+Enter execution, download integration
-
React — hooks-based integration with
useEffectWASM init -
Vue 3 — Composition API with
onMountedWASM init -
Svelte 5 —
$effectrune-based WASM init - Angular — service-based WASM init with standalone components
- Cloudflare Workers — XLSX generation at the edge
- Deno Deploy — server-side XLSX with Deno-native imports
- Service Worker — offline XLSX generation with custom WASM URL
Complete 0.1.x hardening series. 419 tests (171 Rust + 248 TypeScript).
- Style roundtrip: gradient fills, diagonal borders, DXF styles, cell named styles
- Formula metadata: array formulas, shared formulas, formulaRef, sharedIndex
- Feature roundtrip: hyperlinks, comments, data validation, conditional formatting, sheet protection, page setup
- Edge cases: empty workbooks, malformed XML, boundary values
- Error handling: corrupted files, invalid inputs, graceful degradation
- Streaming & benchmarks: 100K row read/write, parallel parsing, buffer scaling
- Utilities: cell refs, dates, format codes, CSV/HTML/JSON conversion
-
push_entity()— zero-allocation XML entity resolution -
Vec::with_capacity()on all XML parse buffers (11 sites) -
from_utf8().unwrap_or_default()replacesfrom_utf8_lossy()(6 sites) -
entries.remove()in StreamingReader — moves data instead of cloning -
drain()incollect_preserved()— moves preserved entries -
#[non_exhaustive]on error enum
- Module-scoped
CELL_REF_REregex (hoisted from hot loop) -
isolatedDeclarations: truein tsconfig - Shared WASM init via
__tests__/setup.ts
- Migration guide: SheetJS
- Migration guide: ExcelJS
- Usage examples cookbook
- Release roadmap
- GitHub Actions pinned to stable versions
- Rust toolchain:
@stable - Node.js engine:
>=24.0.0
First public release.
- Full XLSX read/write with Rust WASM core
- Cell styling — fonts, fills, borders, alignment, number formats via StyleBuilder
- Data validation — list, number, date, text length, custom formula
- Conditional formatting — color scales, data bars, icon sets, formula-based rules
- Frozen panes, hyperlinks, comments, sheet protection, page setup
- Rich text with RichTextBuilder
- Named ranges, document properties, workbook views, calc chain
- Streaming reader/writer for large files
- Parallel sheet parsing (rayon)
- Cell reference utilities, date utilities, format utilities
- Sheet conversion utilities (JSON, CSV, HTML, array-of-arrays)
- Browser Blob download support
- 342 tests (170 Rust + 172 TypeScript)
| Operation | modern-xlsx | SheetJS CE | Factor |
|---|---|---|---|
| Read 100K | 1,155 ms | 4,927 ms | 4.3x faster |
| Write 100K | 5,048 ms | 5,048 ms | 1.0x |
| sheetToJson 10K | 54 ms | 103 ms | 1.9x faster |
-
IIFE browser bundle —
modern-xlsx.min.js(29 KB, gzip 10 KB) exposeswindow.ModernXlsx - CDN distribution — auto-served via jsDelivr and unpkg
-
Browser WASM loader —
detectWasmUrl()auto-detects fromdocument.currentScript.src -
initWasmSync(module)— synchronous init from pre-loaded WebAssembly.Module or bytes -
ensureReady()— lazy auto-init wrapper, no-op if already initialized -
createXlsxWorker()— Promise-based Web Worker API for off-thread operations -
Worker entry point —
modern-xlsx.worker.jswith auto WASM init - Interactive playground — live code editor at docs site
- Framework examples — React (hook + component), Vue 3 (composable + SFC), Svelte 5 (rune + component), Angular (service + component)
- Edge runtime examples — Cloudflare Workers, Deno Deploy, Service Worker
- tsdown array config: 3 parallel builds (ESM + IIFE + Worker)
-
deps.neverBundlereplaces deprecatedexternaloption - Source maps for all build outputs
- WASM binary copied to
dist/modern-xlsx.wasmfor CDN serving
| Output | Size | Gzip |
|---|---|---|
| ESM module | 55 KB | 16 KB |
| IIFE bundle | 29 KB | 10 KB |
| Web Worker | 6 KB | 3 KB |
| WASM binary | 939 KB | — |
- 419 total (171 Rust + 248 TypeScript)
modern-xlsx v1.0.0
Getting Started
Guides
- Charts & Visualizations
- Formula Engine
- Table Layout Engine
- Tables & Print Layout
- Encryption
- Feature Comparison
Reference
Migration
Project