JQuery load script on a click event
<pre><code>$('#selector').click(function() {
    // here I would like to load a javascript file
    // let's say /js/script-on-click-event.js
});
</code></pre>

<p>Is that somehow possible? I'm not sure but I remember reading about a function that does this in JQuery documentation but I cannot find it here, maybe it's been deprecated or I saw it elsewhere?</p>

<p>Basically what I want is to load a script on a click event.</p>
