About dawm
dawm is a headless DOM toolkit for parsing, traversing, manipulating, and serializing HTML/SVG/XML documents. It is purpose-built for server-side, serverless, and edge compute environments where performance and portability are paramount.
The Problem
Existing server-side DOM solutions tend to fall into two camps: feature-rich but slow (like JSDOM), or fast but unfamiliar (custom APIs that require learning new paradigms). dawm bridges this gap with a Rust-powered WebAssembly parser that delivers near-native performance, wrapped in the standard DOM APIs that every web developer already knows.
Key Features
- Blazing fast — Rust/WASM core processes documents at near-native speed.
- Familiar API — Standard DOM interfaces:
Document,Element,querySelector, and more. - Zero dependencies — No external packages. Just dawm and your code.
- Secure — WASM sandbox prevents untrusted content from compromising your application.
- Portable — Runs in Deno, Bun, Node.js, and Cloudflare Workers.
- Standards compliant — Built on
html5everfrom the Servo project.
Use Cases
- Server-side rendering (SSR) frameworks
- Web scraping and data extraction
- HTML email template processing
- Unit testing DOM-dependent code without a browser
- Static site generation with dynamic content
- Content sanitization and transformation pipelines
The Team
dawm is created and maintained by Nicholas Berlette. Contributions from the community are welcome — see the GitHub repository for details on how to contribute.
License
dawm is dual-licensed under MIT and Apache-2.0.