
epubveri — a pure-Rust EPUB validator that runs in the browser (WASM), as a JVM-free alternative to epubcheck
epubcheck (https://github.com/w3c/epubcheck) is the de-facto EPUB validator — but it's Java, so embedding it in a web app or a lightweight pipeline means shipping a JVM. I've been building epubveri: a validator written entirely in Rust (no C dependencies), with a WebAssembly build that validates EPUBs directly in the browser — no JVM, no server, nothing leaves the page.
What it does
- Hand-coded structural checks (OCF/mimetype, OPF metadata, manifest/spine integrity, broken references, nav docs) plus RELAX NG / XPath / Schematron engines for the XHTML/SVG content model.
- Reuses epubcheck's message IDs (RSC-…, OPF-…, HTM-…) so the output is familiar to existing toolchains.
Honest status (measured, not vibes)
Against epubcheck's own test corpus, it currently hits 98.8% exact-message-ID recall on the should-error cases, with ~1% false positives on the valid cases. It's pre-1.0 and not a full drop-in replacement yet — the deepest content-model edge cases and some niche rules are still a climb. But it's fast, embeddable, and already catches real problems in real books.
Just shipped
- WASM package on npm: u/veripublica/epubveri-wasm (validate client-side)
- crates.io name reserved; the functional Rust crate follows once a dependency lands
Code: https://github.com/veripublica/epubveri
Dual-licensed (AGPL-3.0 or commercial). Feedback, bug reports, and especially weird real-world EPUBs that break it are very welcome.