Drupal Association members fund grants that make connections all over the world.
The Speedy module is designed to help speed up front end performance in a site.
Why Do Minified Files Matter?
A majority of the time it takes for a page to load occurs in the front end. According to recent measurements on average, for the most trafficked 50k sites, 87% of the time it took to load the page happened in the front end. Serving smaller files will improve this performance.
Minifying the files removes comments, whitespace, and can even transform parts of functions in ways to make them smaller. For example, a minified drupal.js is 24% the size of the original. The minifier used to generate these files is UglifyJS. This is the same one jQuery uses.
drush smj uglifyjs
The uglifyjs on the end is the path to the uglifyjs command from the cli. It will tell you which files succeeded and if there were errors with any of them. Note, files with errors are generated and the error output is in that files.
- If you modified any core JS files don't use this module. The changes you made will not show up in the sites.
Why Not Use On The Fly Minification?
This is a complicated questions. Here are a few details that guided me to an approach that ships minified files.
- jsmin-php, the PHP version of JSMIN, is no longer maintained. I found some bugs in it, too.
- Inline processing with jsmin-php takes some resources to generate minified files. I did some benchmarks and found the time to be too long for my tastes.
Where did the name come from?
On the children's television show Mr. Rogers' Neighborhood there was the Speedy Delivery Service (for old school mail). That's where the module name comes from.
This module was developed by HP Cloud Services.
- Maintenance status: Actively maintained
- Development status: Under active development
- Reported installs: 3,748 sites currently report using this module. View usage statistics.
- Downloads: 85,374
- Last modified: August 20, 2015
- Stable releases are covered by the security advisory policy.
Look for the shield icon below.