Javascript Beautifier Plugin with Sublime 2

By Sam Deering

Javascript Beautifier Plugin with Sublime 2 uses the the JavaScript formatting python module from The plugin is pretty basic at the moment, doesnt check to make sure you are in a .js file, it just formats the selected text, or the entire file if there is no selection.

More posts on Sublime 2:

Code Before


Select your code and the execute the command

Full instructions below.

Code After


Setup Instructions

  1. Download the sublime format plugin from GitHub.
  2. Type %appdata% in cmd (start>run) and extract the folder renamed to “JsFormat“.
  3. Reload Sublime 2
  4. Select the JavaScript you want to make pretty.
  5. Press CTRL+SHIFT+P (or Tools>Command Pallet) and select Format as the command.
  6. You should now have pretty JavaScript!



Because We Like You
Free Ebooks!

Grab SitePoint's top 10 web dev and design ebooks, completely free!

Get the latest in JavaScript, once a week, for free.