Title: Async Loading JavaScript
Last modified: June 12, 2019

---

# Async Loading JavaScript

 *  Resolved [David Elstob](https://wordpress.org/support/users/davwaiguy/)
 * (@davwaiguy)
 * [6 years, 12 months ago](https://wordpress.org/support/topic/async-loading-javascript/)
 * Raul,
 * I realise you prefer not to use Rocket Loader, which runs the JS asynchronously.
   However, when I try using defer JS using FVM it doesn’t work for me. (You do 
   say it might not work to be fair.)
 * So my point is, how about offering an Async option for JavaScript as well?
 * That way I can forget Rocket Loader completely and will save one HTTP call in
   the process plus my JS won’t be render blocking either.
 * Cheers, David

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Raul P.](https://wordpress.org/support/users/alignak/)
 * (@alignak)
 * [6 years, 12 months ago](https://wordpress.org/support/topic/async-loading-javascript/#post-11634908)
 * I recommend you to read what async really means, and the impact it may have on
   your site functionality.
 * `https://idiallo.com/javascript/async-jquery`
 * Async means that your browser and network will decide when to download the file,
   which can be faster that the time it needs to render the html page, or slower.
   
   If it’s slower (ex: slow 3G mobile), any function that depends on jquery will
   stop working, and since this never behaves the same… you cannot test it, but 
   your users will have trouble.
 * In short, you can only async scripts which work independently, such as ads, or
   libraries that do not depend on anything else AND no inlined code also depends
   on it.
 * jQuery is on most of the cases, render blocking because plugins and themes inject
   inline javascript on the page that rely on jquery being loaded first.
    With async,
   there is no guarantee that it will ever load first, even if for you, it always
   works.
 * Therefore, the only way to preserve the order of scripts is with defer, not async.
   
   You can still use async for other stuff which can load completely independent,
   such as ads or other external scripts.
 *  Thread Starter [David Elstob](https://wordpress.org/support/users/davwaiguy/)
 * (@davwaiguy)
 * [6 years, 12 months ago](https://wordpress.org/support/topic/async-loading-javascript/#post-11635581)
 * Thanks for the response, Raul.
 * The reason that I mentioned Async Loading is because that is how Rocket Loader
   works and after testing with and without Rocket Loader running, my site starts
   rendering faster with Rocket Loader turned on, but Rocket Loader introduces one
   extra call as you know.
 * Also Defer doesn’t always work; we can’t rely on it 100%.
 * So my thinking is if you offered an Async option it would mean it could be used
   instead of Rocket Loader and would give people an other option.
 * Just a thought!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Async Loading JavaScript’ is closed to new replies.

 * ![](https://ps.w.org/fast-velocity-minify/assets/icon-128x128.jpg?rev=1440946)
 * [Fast Velocity Minify](https://wordpress.org/plugins/fast-velocity-minify/)
 * [Support Threads](https://wordpress.org/support/plugin/fast-velocity-minify/)
 * [Active Topics](https://wordpress.org/support/plugin/fast-velocity-minify/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/fast-velocity-minify/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/fast-velocity-minify/reviews/)

## Tags

 * [javascript](https://wordpress.org/support/topic-tag/javascript/)
 * [Rocket Loader](https://wordpress.org/support/topic-tag/rocket-loader/)

 * 2 replies
 * 2 participants
 * Last reply from: [David Elstob](https://wordpress.org/support/users/davwaiguy/)
 * Last activity: [6 years, 12 months ago](https://wordpress.org/support/topic/async-loading-javascript/#post-11635581)
 * Status: resolved