| <title></title> | |
| <body> | |
| <script> | |
| function addPrefetch(url) { | |
| let link = document.createElement('link'); | |
| link.rel = 'prefetch'; | |
| link.href = url; | |
| link.addEventListener('error', () => { | |
| document.title = 'FAIL'; | |
| }); | |
| document.body.appendChild(link); | |
| } | |
| const sxg_url = location.hash.substr(1); | |
| addPrefetch(sxg_url); | |
| setInterval(() => { | |
| const entries = performance.getEntriesByType("resource"); | |
| for (let i = 0; i < entries.length; ++i) { | |
| if (entries[i].name == sxg_url) { | |
| document.title = 'OK'; | |
| } | |
| } | |
| }, 100); | |
| </script> |