Skip to content

chrahunt/jeb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jeb

The JavaScript Extra Beautifier takes your obfuscated or minified JavaScript and performs a few changes to enhance the final output from actual JS Beautifiers such as JSBeautifier (source).

Install node if you haven't, then install using npm install -g jeb. There are a few options to transform your JS. Jeb can:

  • take input from stdin and pipe it to stdout:
> cat minified-js.js | jeb > output.js
  • take a file and overwrite it in-place (backup saved to *.bak):
> jeb minified-js.js
  • take a file and send output where you specify:
> jeb minified-js.js -o output.js

Incorporate into your project with npm install jeb, then:

var jeb = require("jeb");

// ... get source ...

var result = jeb(source);

Development

Clone the repo, run npm install to install development dependencies. To run tests mocha must be installed. Install by running npm install -g mocha then in the root of the project just call mocha.

Included tests cover several cases for each transformation that takes place, but for more thorough testing, jeb is run on larger libraries and the test suites for those projects are run. So far this has been done successfully on the jquery source (the same six errors received on the original build were received on the transformed source with no additional errors).

About

Make minified JS extra beautiful.

Resources

Stars

Watchers

Forks

Packages

No packages published