跪拜 Guibai
← All articles
Vue.js · GitHub · Frontend

Inside JitWord: How One Open-Sourced .doc Converter Proves Enterprise Online Word Is a Hard, Real Problem

By 徐小夕 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

The open-sourcing of doc2docx makes the hardest part of legacy .doc migration inspectable and reusable, which matters to anyone handling decades of Word archives. JitWord's 公文 engine and OFD support also demonstrate that document collaboration must accommodate regional regulations, not just generic editing.

Summary

JitWord targets the gap between Notion-style editors and desktop Word by reimplementing Word's formatting system in the browser: multi-level numbering, complex tables, section breaks, embedded OLE objects, native flowcharts, and comment/revision round-tripping all survive import and export. A CRDT-based sync layer allows multiple users to edit without losing text, and an optional per-section page setting handles formal documents. The project also ships a 公文 (official document) engine, OFD support, a template system with fillable variables, and a batch generation API that turns a JSON payload into hundreds of documents.

The company open-sources its hardest part: doc2docx, a Node.js library (BSD) that converts legacy binary .doc files, so enterprises can audit and extend it. Deployment is private and containerized, with source-level delivery, API/SDK integration, and a unified AI layer supporting DeepSeek, Kimi, Qwen, GLM, Doubao, MiniMax, and custom private models. Pricing sits at roughly ¥30k for a permanent enterprise co-build license, compared to per-seat annual SaaS costs. Trade-offs are limited brand reach, a steeper learning curve, and rendering pressure on extremely large documents, but JitWord is a rare attempt to combine Word fidelity, collaboration, and data control in one product.

Takeaways
— JitWord uses CRDT for conflict-free real-time collaboration, not last-write-wins, with sub-second sync for both documents and spreadsheets.
— Its Word parsing engine preserves multi-level numbering, complex tables (merged cells, cross-page), per-section page settings, OLE objects, and native flowcharts on import/export.
— The project open-sources doc2docx, a Node.js library under the BSD license, to convert binary .doc files to .docx.
— AI is embedded in the writing flow: double-click Ctrl invokes continuation, polish, and error correction; a smart formatting button normalizes headings, spacing, and lists.
— AI supports DeepSeek, Kimi, Qwen, GLM, Doubao, MiniMax, plus private models via a standard protocol; admin controls manage keys centrally.
— The 公文 engine covers red-head elements including document number, secrecy level, urgency, dispatch number, signatory, copy-to list, and layout notes, with an AI assistant for drafting.
— Template engine creates variables for text, table loops, seal positions, and images; the API generates documents in bulk from passed-in data.
— Large documents render on demand via virtual DOM and Canvas, so hundred-page files open quickly.
— JitWord offers source-level delivery, containerized deployment, and a three-tier model: product + SDK + source code.
— Drawbacks: limited brand/ecosystem, rendering pressure on very large documents, steep learning curve, and e-signature is display-only with no legal effect.
Conclusions

Open-sourcing doc2docx is a trust play: enterprises that deploy privately want to verify the parser handling their legacy .doc files, and the BSD license lowers the barrier for adoption and auditing.

The 公文 engine is a moat that Western document tools ignore; by modeling Chinese official document standards, JitWord addresses a regulatory niche that requires local domain knowledge to replicate.

Selling source code and SDK alongside SaaS pushes the business ceiling above a typical subscription model, but it also shifts the burden to support and customization for each buyer.

The emphasis on format fidelity over feature breadth suggests the real cost in enterprise document migration is not collaboration but faithful conversion, which most web editors underinvest in.

Concepts & terms
CRDT
Conflict-free Replicated Data Type; a data structure that lets multiple users edit concurrently without a central resolver, merging changes automatically with no lost updates.
OFD
Open Fixed-layout Document, a Chinese national standard (GB/T 33190) for fixed-layout documents, analogous to PDF but widely adopted in government and military sectors.
doc2docx
An open-source Node.js library (BSD) by JitWord that converts legacy binary .doc files to modern .docx format while preserving formatting and embedded objects.
公文
Chinese official documents with strict formatting rules (red heads, document number, secrecy level, copy-to list) used in government and state-owned enterprises; JitWord includes a dedicated engine and AI assistant for them.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗