I have read the advice about putting SCRIPTs at the bottom (e.g. Is "Put Scripts at the Bottom" Correct?) and I understand the concept.
However, I have a doubt.
If I have an OnClick even that calls a JS function that will fail if the javascript include file has not loaded. I could work around this, but its pretty convoluted.
The nub of my thinking is that after the first page has loaded the script will be cached in the client's browser, so after the first page it won't make any difference to performance where I put the SCRIPT include directive, but it may well make a difference to my OnClick event.
I can see that loading some huge Javascript library is going to be slow, on the first page, potentially causing some/many users to "click off". But for the second-page onwards is there any benefit in having scripts at the end of page?
I'd be grateful for any clarification in case I'm being really thick and overlooking something important; thanks.