zhhz compiled to WebAssembly, running entirely in your browser. No
network calls, no server, no data leaves the page. The OpenCC
dictionaries (~1.3 MiB) are bundled into the .wasm blob
and cached after the first load.
loading wasm…
点击 Convert 后显示结果。
What this is
The .wasm blob is built by wasm-pack --target web
from the same Rust conversion core that ships in the CLI,
npm install zhhz, and pip install zhhz. Open one
dev-tools network tab and you'll see exactly one fetch for
zhhz_bg.wasm on first load; nothing else leaves the browser.
Use the npm package from Node.js / Deno
npm install zhhz
node -e 'const {convert} = require("zhhz"); console.log(convert("汉字", "s2t"));'
Or with Deno:
deno run -A --import-map <(echo '{"imports": {"zhhz": "npm:zhhz@0.7.9"}}') -e 'console.log(await import("zhhz").then(m=>m.convert("汉字","s2t")))'