This little plugin has one job: make all merged scripts produced by the Merge + Minify + Refresh plugin load asynchronously.
Get the plugin on GitHub.
Installation Instructions
- Copy the
merge-minify-refresh-async.php
file to yourwp-content/plugins/
directory (or compress to a zip file and upload in the WordPress backend “Plugins > Add New” - Activate
- That’s it. All the merged scripts will be loaded with the
async
attribute.
Potential Issues
Note that if you have plugins or other code that adds inline Javascript, it probably will break if it’s depending on jQuery (for example) to be loaded and active already.
One workaround is to exclude /wp-includes/js/jquery/jquery.js
from the Merge + Minify + Refresh cache, but you may have to exclude other scripts as well.