Crates.io version Download docs.rs docs

sledgehammer

Breaking the WASM<->JS peformance boundry one brick at a time

Status: There are cracks in the wall.

What is Sledgehammer?

Sledgehammer provides faster rust bindings for dom manipuations by batching calls to js. On the js-framework benchmarks it results in about half of the overhead of wasm-bindgen.

A few runs of the js-framework-benchmark (seems to be quite a bit of variation)

image image image

How does this compare to wasm-bindgen/web-sys:

wasm-bindgen is a lot more general, and ergonomic to use than sledgehammer. It has bindings to a lot of apis that sledgehammer does not. For most users wasm-bindgen is a beter choice. Sledgehammer is specifically designed for web frameworks that want low level, fast access to the dom.