github cjnoname/excelts v10.1.0

3 hours ago

πŸš€ ExcelTS 10.0.0 β€” the final major release

Read this first. This is the last major version of ExcelTS in its current shape.

Work is already underway on a brand-new project that re-architects the Excel core from the ground up for first-class tree-shaking β€” so you only pay for the bytes you actually import. The current monolithic Workbook surface makes deep tree-shaking impossible; the next project fixes that at the structural level while keeping the zero-dependency, cross-platform, streaming-first philosophy.

You don't need to worry about migration. The new project is being designed to be trivially portable. I will ship a complete, AI-ready migration guide so an AI agent can move an existing ExcelTS codebase to the new project in a single pass β€” no manual rewrites, no guesswork. Stay on 10.x with confidence; upgrading later will be effortless.


πŸ“„ Headline: the Word module is now official

This release graduates Word (DOCX) to a first-class, fully documented module β€” bringing ExcelTS to nine modules (Excel, Word, Formula, PDF, CSV, Markdown, XML, Archive, Stream).

A zero-dependency, cross-platform DOCX toolkit that reads, writes, and converts Word documents:

  • Authoring β€” paragraphs, headings, rich-text runs, tables (merges + nesting), images (inline/floating, incl. SVG with raster fallback), bulleted/numbered/multi-level lists, sections, headers/footers, page layout
  • References & fields β€” hyperlinks, bookmarks, table of contents, footnotes/endnotes/comments, and a field engine (PAGE/NUMPAGES, TOC, INDEX/XE, REF, SEQ, STYLEREF, formulas)
  • Rich content β€” OMML math, drawing shapes (fill/line/gradient/shadow/glow/3-D), charts (preserved + from-scratch builder, bridged to the Excel chart engine)
  • Editing & review β€” read/modify, text search/replace, format-aware queries, track-changes accept/reject, document diff & merge
  • Templating & data β€” {{variable}} / {{#if}} / {{#each}} templates, mail merge, form fields & content controls (SDT), OpenDoPE data binding
  • Conversion β€” DOCX ↔ HTML, DOCX ↔ Markdown, Excel β†’ Word, Word β†’ PDF
  • Production concerns β€” font embedding with subsetting, document protection, Agile-encryption decrypt/encrypt, digital-signature inspection, Flat OPC, streaming writer, validation, ISO 29500 Strict normalization, and full browser support

Docs: src/modules/word/README.md Β· δΈ­ζ–‡ Β· 47 runnable examples under src/modules/word/examples/.

import { Document, toBuffer, readDocx } from "@cj-tech-master/excelts/word";

const doc = Document.create();
Document.addHeading(doc, "Report", 1);
Document.addParagraph(doc, "Generated by ExcelTS.");
const bytes = await toBuffer(Document.build(doc));

πŸ“¦ What's in this release

Full diff: v9.6.1...v10.0.0

⚠ BREAKING CHANGES

  • word: markdownToDocx and markdownToDocxBody are now async; markdownToDocxBody returns MarkdownBodyResult instead of BodyContent[].

Features

  • Add support for glossary (Building Blocks) and OLE embedded objects (19beef5)
  • excel: Add shapes, SVG images, configurable note size, nested column keys (ad7c201)
  • word: Embed images and footnotes in markdown-to-docx conversion (9ec00a6)
  • word: Enhance glossary handling with self-contained sub-documents and strict gallery validation (d82b397)
  • word: Enhance watermark functionality with custom dimensions and improved rendering (b780dbb)

Bug Fixes

  • pdf: Preserve non-WinAnsi text and improve DOCXβ†’PDF flow fidelity (5b34a35)
  • word: Correct HTMLβ†’DOCX class style merging and list/image handling (8264c23)
  • word: Correct list IR conversion, compat-mode round-trip, and INDEX field (a8bf9bc)
  • word: Correct math phantom visibility, MathML run tokenization, style-map overrides, and theme color casing (82e6dd6)
  • word: Hide empty degree when importing a square root from MathML (aaf6992)
  • word: Preserve list structure and numbering format in ODT round-trip (bf6736a)

Don't miss a new excelts release

NewReleases is sending notifications on new releases.