minify

Production ready alternative to Microsoft Doloto (Javascript minifier/prefetcher)?

As you surely know Microsoft Doloto is tool which profiles you javascript code as it actually runs on the page and splits it in to two files: one file will be statically included in the footer of the page which contains stubs for all functions and loads the actual implementations (in file 2) in the background (under the assumption that o...

Better to combine & minify javascript or use Google CDN?

I am building a site which currently uses javascript from several sources: Group 1: Google Maps API v3 (hosted by Google) Group 2: jQuery & swfobject (hosted on Google CDN) Group 3: Several jQuery plugins and non-jquery javascript files (hosted on my server) I am using Justin Etheredge's tool SquishIt to combine and minify all the java...

Why does Google's Closure Compiler leave a few unnecessary spaces or line breaks?

I've noticed that every time I use Google's Closure Compiler Service, it leaves a few unnecessary spaces in the compiled code presented on the right-hand side of the page. These correspond to line breaks in the hosted version of the compiled code. For example (note the line breaks, each of which seems unnecessary): http://troy.onespot....

Most flexible minimizer/compressor for ASP.NET MVC 2?

From your experience, what's the most flexible minimizer/compressor (JS+CSS) for ASP.NET MVC you've dealt with? So far mbcompress doesn't seem to be too MVC friendly weboptimizer.codeplex.com lacks documentation clientdependency.codeplex.com is still in beta compress2 seems like a good candidate, but haven't tried it yet mvcscriptmana...

Visual Studio 2010 and javascript debugging in external javascript files (embedded and minified).

Hi, The asp.net web application I'm working on is written in asp.net 3.5, the web app solution is upgraded from VS 2008 (don't know if that matter). The solution had javascript in the aspx files before I moved the javascript to external files. Now what I have done is to set all the javascript files to be embedded resource (except the ...

Evaluating php generated javascript "inline"?

If you look at the source of this page http://kingston.talking-newspapers.co.uk/ you will see a large amount of inline javascript near the top. I don't really want all this extra stuff floating around in my page source, I'd much rather get it off into a script tag, and then I can minify it and all sorts. If I call it as a php file, thi...

Django: auto minifying css/js files before release

Hi, I have following case: I want to use uncompressed js/css files during development (to debug js for example) but on production I want to switch automatically to minified versions of that files. some simple solution is to put in your template: <script src="some_js.{% if not debug %}min.{% endif %}js".... but this require manully p...

Asp.Net MVC Combine and remove inline scripts during response.

I have been doing some performance analysis on a few websites I am working on and I am noticing that a big problem is the inline scripts. For the external scrips I wrote an http handler which combines, minifies, and gzips the javascript into one file. This is then stored for reuse later by hashing the filenames. What I am wondering (...

Minify HTML/PHP

I'm using gzip to compress my html/php files along with js/css/etc. This reduces the payload quite nicely but I also want to 'minify' my markup of both .html and .php pages. Ideally I'd like to control this from a .htaccess file (where I also do the gzipping) rather than the having to include php to each file. I'd like the output to be ...

Are the ways or plugins to automatically minify CSS, Html and Javascript code in Vim?

I would like to know if there's a way of automatically minify html, css or javascript files. So that each time I save the "source file" Vim automatically make the same changes to a minified version of the file (or automatically creates or override a minified version). Something like this: Source: // The -is- object is used to identif...

When I minify css or js, why isn't it all on one line?

I understand that minifying tries to reduce file size by removing whitespace characters. Sometimes things end up on one line, but more often than not, there are multiple lines. I noticed that line breaks happen wherever spaces occur. Wouldn't it be better just to have it all on one line? ...

Improving the web site performance

Hi, I have a pretty big web site (asp.net web) and I have used JavaScript intensively (jquery,custom javascipt, etc) and also The theme and CSS. Right now I have a huge amount of js and css files in my system and I am thinking about minifying and smashing the js and css to improve the performance. So, please advice me the suitable too...

javascript packer versus minifier

I was wondering what the differences/benefits of the packer vs the minifier were, i.e. Should you deploy a packed or minified version in your web app? Example code: var layout = { NAVVISIBLE : 1, Init : function() { this.Resize(); }, Dimensions : function() { var d = document, s = self, w, h;...

Minify inline css code before its written to database, then unminify it when editing

My theme has a custom css code block where I allow the site owner to add any custom css they need directly to the head section of the theme. This inserts whatever they've placed in this block into the wordpress database as a custom option insert. I then retrieve this content into header.php and output it between an inline style tag like...

How do I turn off minified JavaScript under Richfaces?

For the purposes of debugging I need to make Richfaces use non-minified JavaScript. Is there a simple way to accomplish this? ...

Minify jQuery with PHP

Hello, What is the best way to minify jQuery with other js files. My goals is one request for all my JS files. I have about 6 other js files that I would like combine with jQuery and the jQuery UI. When I leave the jQuery library and UI library out of the minification file it is fine. So I have three requests: jQuery library jQuery UI...

What does jQuery use to minify their css and javascript?

I know that they use Google Closure for their Js files in 1.4 but what about css? ...

How to Optimize Combres Settings (Compression, Minification)

Can anybody tell me the most optimal Combres settings? I've got the following but it appears as though my CSS and my JS are not being minified. <?xml version="1.0" encoding="utf-8" ?> <combres xmlns='urn:combres'> <filters> <filter type="Combres.Filters.FixUrlsInCssFilter, Combres" /> <filter type="Combres.Filters.D...

Integrate Google closure compiler with Eclipse IDE?

Does anybody know how to integrate Google closure compiler with Eclipse IDE? The thing I was trying to do is to configure Google closure compiler as a external tool for Eclipse IDE. Then I would be able to run closure compiler within IDE and minify my Javascript files with single click. Have anybody solved this problem yet? ...

Should I use minified or regular versions of jQuery plugins during development and deployment?

As many of you know, most jQuery (or javascript, for that matter) plugins you find these days can be downloaded as either regularly formatted code, minified version, or both. For development purposes, I like to use the non-minified versions of the plugins, in case I need to set a Firebug breakpoint or look through it for any reason. Now...