diff options
Diffstat (limited to 'plugins/jetpack/_inc/connect-button.js')
-rw-r--r-- | plugins/jetpack/_inc/connect-button.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/plugins/jetpack/_inc/connect-button.js b/plugins/jetpack/_inc/connect-button.js index c2317efd..16681ea9 100644 --- a/plugins/jetpack/_inc/connect-button.js +++ b/plugins/jetpack/_inc/connect-button.js @@ -121,6 +121,13 @@ jQuery( document ).ready( function( $ ) { } ); jetpackConnectIframe.hide(); $( '.jp-connect-full__button-container' ).after( jetpackConnectIframe ); + + // At this point we are pretty sure if things work out that we will be loading the admin script + var link = document.createElement( 'link' ); + link.rel = 'preload'; + link.as = 'script'; + link.href = jpConnect.preFetchScript; + document.head.appendChild( link ); }, fetchPlanType: function() { $.ajax( { |