回答編集履歴
2
chousei
    
        answer	
    CHANGED
    
    | @@ -9,4 +9,14 @@ | |
| 9 9 | 
             
              });
         | 
| 10 10 | 
             
              document.head.insertBefore(script,document.head.querySelector('script'));
         | 
| 11 11 | 
             
            });
         | 
| 12 | 
            +
            ```
         | 
| 13 | 
            +
            調整
         | 
| 14 | 
            +
            上記若干調整してこんなふうでも良いかも
         | 
| 15 | 
            +
            ```javascript
         | 
| 16 | 
            +
            window.addEventListener('load',async()=>{
         | 
| 17 | 
            +
              const script=Object.assign(document.createElement('script'),{
         | 
| 18 | 
            +
              src:window.URL.createObjectURL(new Blob([await fetch('https://raw.githubusercontent.com/lot-uni/CDN/main/alert.js').then(res=>res.text())]))
         | 
| 19 | 
            +
              });
         | 
| 20 | 
            +
              document.head.insertBefore(script,document.head.querySelector('script'));
         | 
| 21 | 
            +
            });
         | 
| 12 22 | 
             
            ```
         | 
1
chousei
    
        answer	
    CHANGED
    
    | @@ -1,2 +1,12 @@ | |
| 1 1 | 
             
            マイムタイプが一致しないというエラーが出ているようです
         | 
| 2 | 
            -
            - [X-Content-Type-Options - HTTP | MDN](https://developer.mozilla.org/ja/docs/Web/HTTP/Headers/X-Content-Type-Options#%E3%83%87%E3%82%A3%E3%83%AC%E3%82%AF%E3%83%86%E3%82%A3%E3%83%96)
         | 
| 2 | 
            +
            - [X-Content-Type-Options - HTTP | MDN](https://developer.mozilla.org/ja/docs/Web/HTTP/Headers/X-Content-Type-Options#%E3%83%87%E3%82%A3%E3%83%AC%E3%82%AF%E3%83%86%E3%82%A3%E3%83%96)
         | 
| 3 | 
            +
             | 
| 4 | 
            +
            見た感じCORSには引っ駆らないようなのでどうしてもというのであればこんな感じで
         | 
| 5 | 
            +
            ```javascript
         | 
| 6 | 
            +
            window.addEventListener('load',async()=>{
         | 
| 7 | 
            +
              const script=Object.assign(document.createElement('script'),{
         | 
| 8 | 
            +
              textContent:await fetch('https://raw.githubusercontent.com/lot-uni/CDN/main/alert.js').then(res=>res.text())
         | 
| 9 | 
            +
              });
         | 
| 10 | 
            +
              document.head.insertBefore(script,document.head.querySelector('script'));
         | 
| 11 | 
            +
            });
         | 
| 12 | 
            +
            ```
         | 
