Reputation: 68074
Is there a service out there that provides public API for compressing CSS or Javascript?
(Like imgur let's you upload images trough PHP and get the image URL)
Upvotes: 5
Views: 2342
Reputation: 9315
I am using .Maui and it is awesome! You can minify and combine CSS and JS using the web tool or the free API. For JS it even optimize the code and is ES5 and ES6 compatible! There are other useful tools like Sitemap Generator, HTML Minify, Image Resizer and Free CDN for the minified files.
Before i tried Google Closure Compiler, cssminifier.com and javascript-minifier.com, but they have restrict limits of POST size and number of requests per second.
Upvotes: 0
Reputation: 1117
You can use jsCompressor and CSSCompressor for minifing your javascript and css code.
Upvotes: 0
Reputation: 1305
Another online tool you can use to minify/compressing your js is http://samqode.com/minifyjs . very soon There will be a public API available for on the fly (via url request) minification so its a good one to watch out for.
Upvotes: 1
Reputation: 49
I prefer using the tool on www.blimptontech.com for minifying my Javascript files. They also have a feature to combine your files into one and minify at the same time. I like it because it uses UglifyJS to get the dirty work done.
Upvotes: 1
Reputation: 1115
Pretty Diff can minify CSS, JavaScript, and HTML.
http://prettydiff.com/?m=minify&html
Upvotes: 1
Reputation: 8846
Google Closure Compiler let's you send JavaScript code with POST request and returns optimalized code.
Upvotes: 4
Reputation: 3034
The YUI compressor by Yahoo is your best bet. You can download it (http://developer.yahoo.com/yui/compressor/), or use an online solution: http://www.refresh-sf.com/yui/
It does CSS and JavaScript.
Upvotes: 1
Reputation: 154968
The Closure Compiler can be used for JavaScript. It has an API (link on the top right hand corner). It does a decent job on compiling JavaScript.
Upvotes: 2