This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 166269 - Javascript compact/minimize/pack
Summary: Javascript compact/minimize/pack
Status: NEW
Alias: None
Product: javascript
Classification: Unclassified
Component: Editor (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Petr Pisl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-29 20:24 UTC by caesar2k
Modified: 2014-01-16 10:27 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description caesar2k 2009-05-29 20:24:50 UTC
Aptana got a nice feature that does the opposite of "format". It "minifies" the javascript code, to make it more compact.
A code like this:
function hello( id ){
  if (id > 0){
    $("#f" + id).attr('target', null);
  }
}
turns into this:
function hello(id){if(id>0){$("#f"+id).attr('target',null);}}

Not too hard to accomplish imo. it's not rewriting variables, it's not "packing" the code, it's just inlining/trimming
spaces.