Unfortunatelly I can't register on the joomla forum, so I'll try my best here.
Please help, is there any way to control the order of loaded scripts.
Example: in my template's index.php I do:
as the very first addScript(); So I load that script globally for all pages.
Then, in the default.php of my custom component I do:
to add additional behaviour for that very component view specifically.
Logically I would assume that the addScripts in the index.php are added to the $doc object first and after that the addScripts in the component view are appended $doc object.
But what I end up with in the head is:
<script src="my/script_b.js"></script> <script src="my/script_a.js"></script>
This bugs me pretty hard since my/script_a.js performes calculations my/script_b.js depends on, so the order is crucial.
Please, there must be a way to control the order of loading scripts otherwise this feature is pretty much pointless, isn't it?