Step 1: Set the type
attribute of your script
tag to something invalid, such as "invalid", or your favorite swear-word.
<script type="invalid" src="path/to/script.js" id='myScript'></script>
Step 2: At some later point, when the script has been loaded (such as, after window.onload event has occurred), just do this:
var myScript = document.getElementById('myScript');
document.head.removeChild(myScript);
myScript.setAttribute('type', 'text/javascript');
document.head.appendChild(myScript);
If you do it this way, you'll be an outlaw. The table manners and best practices crowd will shudder - that type is not in the spec - the computer will esplode!!. So you might as well use a 4 letter word for the type and giggle hysterically.
Update
also works with inline scripts.