npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@wakaru/cli

v1.7.0

Published

Fast JavaScript decompiler and bundle splitter (Rust)

Downloads

2,289

Readme

@wakaru/cli

Fast JavaScript decompiler and bundle splitter for modern frontend code.

Quick Start

npx @wakaru/cli input.js -o output.js               # decompile a file
npx @wakaru/cli bundle.js --unpack -o out/          # unpack and decompile a bundle
npx @wakaru/cli dist/ --unpack -o out/              # scan a bundle output directory

Install

npm install -g @wakaru/cli@latest
wakaru input.js -o output.js

What It Does

  • Splits bundles from webpack 4/5, esbuild, Bun, Browserify, SystemJS, and AMD.
  • Recovers readable JavaScript from transpiler and minifier output.
  • Supports source maps for name recovery and output mappings.
  • Offers minimal, standard, and aggressive rewrite levels.

CLI Reference

Decompile a single file

wakaru input.js -o output.js
cat input.js | wakaru > output.js

Without -o, output goes to stdout. Stdin is supported for single-file decompilation.

Unpack bundles and chunks

wakaru bundle.js --unpack -o out/
wakaru bundle.js --unpack --raw -o out/
wakaru bundle.js --unpack=strict -o out/
wakaru entry.js chunk.js --unpack -o out/
wakaru dist/ --unpack -o out/
  • --unpack splits detected bundles and then decompiles each module.
  • --unpack --raw writes extracted modules before the readability pipeline.
  • --unpack=strict uses structural bundle detection without heuristic fallback.
  • Directory inputs are recursive and detect-only; skipped files are not copied.

Formatter

wakaru input.js --formatter -o output.js
wakaru bundle.js --unpack --formatter -o out/

--formatter runs a final formatting pass after decompilation. It is off by default.

Source maps

wakaru input.js --source-map input.js.map -o output.js
wakaru input.js --emit-source-map -o output.js

--source-map improves name recovery from the original source map. --emit-source-map writes a .map file that maps the decompiled output back to the input.

Extract original sources

wakaru extract input.js.map -o src/

Writes files embedded in a source map's sourcesContent to disk.

Rewrite levels and cleanup

wakaru input.js --level minimal
wakaru input.js --level standard
wakaru input.js --level aggressive
wakaru input.js --dce
  • minimal keeps to high-confidence, low-risk rewrites.
  • standard is the default readability-oriented mode.
  • aggressive enables more speculative generated-code recovery.
  • --dce opts into a full dead-code reachability sweep.

JSON, diagnostics, and profiling

wakaru bundle.js --unpack --json -o out/
echo 'var a=1;' | wakaru --json
wakaru input.js --diagnostics
wakaru input.js --profile trace.json
wakaru input.js --profile trace.json --profile-rules
  • --json writes structured JSON to stdout.
  • --diagnostics reports post-transform warnings to stderr.
  • --profile writes a Chrome trace file.
  • --profile-rules includes per-rule timings in the trace.

Overwrite protection

Wakaru refuses to overwrite existing files unless --force is passed.

Links

  • Repository: https://github.com/pionxzh/wakaru
  • Documentation: https://github.com/pionxzh/wakaru#readme
  • Releases: https://github.com/pionxzh/wakaru/releases