New answers tagged


Loading scripts using async means that the loading process of your scripts will not interrupt the rendering of your webpage. This allows your web page to render more quickly as parsing is not paused every time a script must be loaded. This also allows for multiple scripts to be loaded concurrently which is beneficial given that one script does not depend ...


The async attribute is useful for a script that: Doesn't depend on whether the HTML is fully loaded Shouldn't block the HTML Yet should still be executed ASAP A perfect example of this is an analytics script. If you loaded it without any attributes, it would block the rest of the page's rendering. If you loaded it with defer, it would run unnecessarily ...


use ga instead of GTM-P8F58CT (window,document,'script','dataLayer','GTM-P8F58CT') if it didn't solve the problem use __gaTracker()


First way: Google crome provide easy way to check used or unused js and css. Right Click + Inspect Element on the page, find the three dots on the far right (circled in image) and open Console Drawer (or hit Esc), finally click the three dots left side in the drawer (circled in image) to open Coverage tool. Chrome launched a tool to see unused CSS and JS -...

Top 50 recent answers are included