I'm trying to include a script by including it in script src
<script type="text/javascript" src="http://some-site.com/script.js"></script>
Sometimes this fails with a 401 error. It is also a script, which is returned, which would be nice to read and execute here in any case. But for that I'd need to read the response.
I know there is an answer here, but I'm trying to do it without XHR, because the response on XHR is different (403), as is the content (otherwise I wouldn't care).