A good tool for minimizing prints?
Does anyone know of a good tool that can be run on a page (for asp.net for example) to minimize the page size on the page?
The page will have typical elements: HTML, Javascript, etc.
I've heard in the past about Junchers-crunchers which will keep the code size as compact as possible (and let's assume it confuses it).
The goal is to help optimize the page size (keep it as small as possible for speed, without changing anything).
Is it possible?
source to share
Well, it's not automatic clean-top, but I love YSlow for page optimization. And YUI Compressor can minify your javascript.
If you are really interested in javascript, the keyword is "minify".
Also look at this question only: HTML and stuff
Hope it helps!
source to share
Yes, definitely. I'm not an asp.net guy, but things you might be looking for (as others have said):
- gzip compression for page - a server
- js: as you said, there are mini options for javascript, which in turn might be fine.
- css: there are customization options like javascript and can also be gzipped.
Our java applications use pack: tag . Perhaps you can find a similar replacement for .net.
Yslow, already mentioned, can show you what improvements you can make.
source to share
Find some ASP.NET compression methods, if you are running on IIS6, I recommend you MbCompression , however if you start IIS 7 with excellent built-in support for HTTP compression , you can determine which files will be compressed based on their MIME type in your config files.
source to share
Few reasons: IIS stores the compressed response of the JS / CSS / Html files on disk, so subsequent requests for JS / CSS are served from disk (bypassing the compression step). Although the compressed response for ASPX / ASCX is not cached to disk, as the response depends on the request for the request.
So it's best to keep Javascript / CSS in your files and not inject inline CSS / Script in aspx / ascx.
In general there are two ways to reduce the page size / HTML 1) Compression by Web Server / HTTPModule Enable IIS 6 HTTP Compression [1]
2) Third party tool obfuscation / compression - JASOB is my favorite.
It can also compress / obfuscate javascript / css code from php / asp.net / perl / jsp / XSLT file. And if vanila DOS for example, then there is a command line interface.
I've used it on several ASP.NET projects, I just select my web projects directory and JASOB provides a good option for posting a convoluted version of the web projects directory. This means it obfuscates the javascript / css from all files under your web projects directory and yes, it moves sub directories as well. And all this with one click.
Hope it helps, Maulik Modi http://www.jasob.com/Features.html
source to share