@script()directive. The only major difference
is that any script pulled by @onscript() directive will be pulled into the javascript's
window.onload() method.
#script:js1 function hi(){ console.log('hi') } #script; #script:js2 hi(); #script;
@script('index:js1')
@onscript('index:js2')
<script>
function hi(){
console.log('hi')
}
</script>
<script>
window.onload = function() {
hi();
}
</script>
@script() and @onscript() template
directives.