AEM doesnot have control over third party script. If we are injecting third party script make sure we follow best practices such as minification of script, removing the blocking resources, defer loading, optimisation etc.
Lighthouse plugin in chrome developer tool is one of the good plugin which reports about improvements and solution to increase the performance of site.
You can follow the best practices document along plugin as well.
Put CSS includes in HTML <head> tag – this helps avoid flickering and repainting of the page after load.
For example: <script src="//includes1.yoursite.com/etc/clientlibs/test.js"></script> <script src="//includes2.yoursite.com/etc/clientlibs/test2.js"></script>