diff --git a/apps/api/documents/api.js b/apps/api/documents/api.js index a82ecf2a1c..94dafac491 100644 --- a/apps/api/documents/api.js +++ b/apps/api/documents/api.js @@ -1303,5 +1303,15 @@ return path; } + (function() { + if (document.currentScript) { + var scriptDirectory = document.currentScript.src; + var cacheWarmupId = /[?&]cacheWarmupId=([^&#]*)?/.exec(scriptDirectory); + if (cacheWarmupId && cacheWarmupId.length ) { + DocsAPI.DocEditor.warmUp.call(this, decodeURIComponent(cacheWarmupId[1])); + } + } + })(); + })(window.DocsAPI = window.DocsAPI || {}, window, document); diff --git a/apps/api/documents/cache-scripts.html b/apps/api/documents/cache-scripts.html index f9e68dd6ef..97a40b24d1 100644 --- a/apps/api/documents/cache-scripts.html +++ b/apps/api/documents/cache-scripts.html @@ -11,12 +11,28 @@ + - + + + + + + + + + + + + + + + +