FAQ
Common questions about Wakaru.
How is Wakaru different from a formatter or beautifier?
A formatter only changes whitespace and layout. Wakaru rewrites the JavaScript AST to reverse minifier artifacts, restore transpiled syntax, remove bundler runtime patterns, and split bundles back into modules.
How do I unminify JavaScript?
Run npx wakaru input.js -o output.js, or paste the code into the
playground. Wakaru reverses minifier
artifacts (sequence expressions, !0/void 0 literal tricks, flipped
comparisons) and transpiler helpers (Babel, TypeScript, SWC) to recover
readable modern JavaScript.
How do I decompile a webpack bundle?
Run npx wakaru bundle.js --unpack -o out/. Wakaru detects webpack 4/5 and
the other formats listed in Unpack a bundle, then
splits the bundle into individual modules and decompiles each one.
Can Wakaru extract JavaScript from a Bun single-file executable?
Yes. Run npx wakaru ./compiled-app --unpack -o out/ on a
bun build --compile binary. Wakaru validates Bun's
embedded module graph and decompiles the JavaScript entries without ever
executing the binary. npx wakaru bun extract ./compiled-app -o extracted/
dumps every embedded file, assets included.
Can Wakaru deobfuscate JavaScript?
No. Heavy obfuscation such as string arrays, control-flow flattening, and VM-based protectors is a different problem. Strip it first with a dedicated tool like webcrack, then use Wakaru to recover readable modules. See What is Wakaru for the pipeline.
Can it recover original variable names?
Yes, when the source map includes original names: Wakaru recovers them and deduplicates imports. Without one, it applies conservative renaming heuristics where the code gives evidence, but most mangled names stay short. Pair it with an LLM renamer like humanify if you want guessed names.
Is the output guaranteed to behave the same?
Wakaru is designed to preserve behavior while recovering readable structure.
Rewrite levels let you choose between behavioral
fidelity and stronger readability-oriented recovery. Use minimal when
fidelity matters most. A Test262 round-trip harness continuously measures
semantic preservation.
Does it run in the browser?
Yes. The playground is the WebAssembly build of the same Rust engine, running entirely in your browser. No code leaves your machine.