TL;DR

Silurus/ooxml is a new open-source project that enables rendering Office Open XML documents precisely in web browsers using Rust, WebAssembly, and Canvas. It offers format-specific viewers with customizable UI options, including support for equations via MathJax. The project is currently in development with available demos and integration instructions.

Silurus/ooxml, an open-source project, has released a browser-based library that renders Office Open XML documents with pixel accuracy directly in web browsers. Built entirely in Rust and compiled to WebAssembly, it supports DOCX, XLSX, and PPTX formats, offering developers a highly customizable way to display Office documents without relying on external viewers or server-side rendering.

The project includes Rust parsers for each Office format, compiled into WebAssembly modules that parse ZIP archives into JSON models. You can learn more about office document storage solutions. These models are rendered on HTML Canvas elements using a custom TypeScript renderer that maintains pixel fidelity. The library supports features like page navigation, slide transitions, and chart rendering, with optional equation support via MathJax integrated into the rendering engine.

The implementation is modular: each format has its own parser and renderer, with shared core primitives for shapes, charts, and styling. Parsing occurs in Web Workers to keep the UI responsive, and rendering happens on the main thread, sharing font sets for accurate text layout. The library is distributed as an ESM-only package, with size optimizations allowing tree-shaking of unused features such as the math engine.

Why It Matters

This development matters because it enables web applications to display Office documents with high visual fidelity without relying on proprietary viewers or server-side conversions. It opens possibilities for embedded document viewers in web apps, online collaboration tools, and custom UI integrations, reducing dependency on external software and improving performance and privacy.

Moreover, the use of Rust and WebAssembly ensures high performance and portability, making this approach scalable for large or complex documents. The project also demonstrates how modern browser APIs and WASM can be combined to achieve pixel-perfect rendering traditionally limited to native applications.

Ultimate Office AdjustaView 10-Pocket Desk Reference Organizer with Supplies Storage Base and EZ-LOAD Pockets to Hold 20 Sheets of Paper, Includes Fast Find Indexing Tabs (Colored Pockets)

Ultimate Office AdjustaView 10-Pocket Desk Reference Organizer with Supplies Storage Base and EZ-LOAD Pockets to Hold 20 Sheets of Paper, Includes Fast Find Indexing Tabs (Colored Pockets)

DESKTOP DOCUMENT DISPLAY ORGANIZER – Keep your most-referenced documents, procedures, price lists, and schedules instantly visible at your…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Background

Existing solutions for rendering Office documents in browsers often rely on converting files to HTML or images, which can compromise fidelity or be resource-intensive. For hardware and accessories to improve your office setup, see our office printer recommendations. The Silurus/ooxml project builds on recent advances in WebAssembly and Rust to provide a native-like rendering experience directly in the browser. The project was developed through iterative prompting of an AI assistant, resulting in a complete codebase with parsers, renderers, and tooling, emphasizing modularity and performance. The release follows a broader industry trend toward in-browser document processing and visualization, with similar efforts in PDF rendering and SVG-based viewers. For backup solutions to safeguard your documents, check out backup server appliances.

“The parsers are written in Rust, compiled to WebAssembly, and use the Canvas 2D API for rendering, supporting detailed features like equations and charts.”

— Developer documentation

Amazon

WebAssembly Office document rendering tool

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

What Remains Unclear

It is not yet clear how well the library performs with very large or complex documents, or how it compares in fidelity and speed to native or server-side solutions. The current status is primarily developmental, with demos available but no official production release announced.

Amazon

DOCX XLSX PPTX viewer online

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

What’s Next

Future steps include optimizing performance for large documents, expanding feature support (such as more complex equations and multimedia), and integrating with popular web frameworks. The developers plan to release more comprehensive documentation, tutorials, and potentially a plugin ecosystem to enhance customization and usability.

Plustek OS1180 - Flat Scanner for Graphics and Documents in A3 Format, Design Suitable for Libraries, Schools or Small Offices - Scanning A3 Documents in Approximately 9 Seconds

Plustek OS1180 – Flat Scanner for Graphics and Documents in A3 Format, Design Suitable for Libraries, Schools or Small Offices – Scanning A3 Documents in Approximately 9 Seconds

Maximum Scan size – 11.7"x 17" (297 x 431.8 mm) Large Format Scanning, easy digital Tabloid or A3…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Key Questions

Can Silurus/ooxml render all Office document features?

It currently supports core features of DOCX, XLSX, and PPTX formats, including text, shapes, charts, and equations. Support for advanced features like macros or embedded media is limited or not yet implemented.

Is this library suitable for production use?

As of now, it is primarily in development with demos available. Further testing and optimization are needed before it can be recommended for production environments.

How does it handle equations and formulas?

Equations in DOCX and PPTX files are rendered using MathJax integrated into the engine, which is optional and can be tree-shaken away to reduce bundle size if not needed.

What browsers are supported?

The library relies on WebAssembly and Canvas, which are supported in all modern browsers, including Chrome, Firefox, Edge, and Safari.

How can I try or contribute to Silurus/ooxml?

The project is open-source; you can find the codebase and demos on its repository, with instructions for installation and integration provided in the documentation.

Source: Hacker News

You May Also Like

The PDF Compression Trick That Doesn’t Destroy Quality

A simple trick to compress PDFs without losing quality—discover how to preserve clarity while reducing file size effectively.

OCR: Turning Scans Into Searchable Text

With OCR technology, turning scans into searchable text can revolutionize your workflow—discover how it can benefit you today.

Mobile Scanning Apps: Features and Privacy Considerations

Portable and user-friendly, mobile scanning apps offer powerful features but pose privacy questions—discover how to maximize security while enjoying their benefits.

Organizing Digital Documents With Cloud Storage

Prioritize effective folder structures, naming conventions, and tags to streamline your digital document organization—discover how to optimize your cloud storage today.