ZF-6031: Feature to combine and minify a set of javascript and css requests

Issue Type: Improvement Created: 2009-03-14T06:08:47.000+0000 Last Updated: 2009-03-14T07:36:56.000+0000 Status: Resolved Fix version(s): Reporter: Prem Pillai (premjg) Assignee: Matthew Weier O'Phinney (matthew) Tags: - Zend_View

Related issues: Attachments:


Add a feature to combine and minify a set of JavaScript and CSS requests on a Zend_view instance. With javascript libraries getting so popular with developers, a decent web 2.0 application has at least 10 to 12 javascript http requests made by the client. One way to deal with this is by manually minifying and collating thereby creating workable sets of files and including it. I'm currently using the following script to do the job automatically but it will great to have it integrated into Zend.


Posted by Matthew Weier O'Phinney (matthew) on 2009-03-14T07:36:34.000+0000

Dojo provides tools for this out of the box via its build system (using shrinksafe for JS and minify for CSS), and we are currently working on functionality to somewhat automate the process.

One thing to note: minification should never happen during requests. It can often lead to race conditions if you have many requests at once to the site as it is a non-trivial process. It is much better to do this as part of your build system for deployment of your site. Dojo's solution in this regard is perfectly appropriate.

If you would like to see a more generic process for minification, please create a proposal, as it is a non-trivial feature request.

Have you found an issue?

See the Overview section for more details.


© 2006-2021 by Zend by Perforce. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.