Scripts are one of the main parts of a website that slow down the loading of a page, however they are important for implementing all sorts of functionality on a website. This is why it is essential to optimize scripts to improve page load times.
Leap provides several features that can help you achieve this within the Leap dashboard > Optimize > Optimization settings > Script execution
Within this category there are several advanced settings to help optimize scripts:
Script Delay - Delays the loading and execution of Javascript until the primary content has loaded, this helps to prioritize the loading of the content improving LCP.
Reduce CPU Intensive Tasks - Slows down javascript tasks that are using up too much CPU so the browser's processor has free time to render the page to improve LCP. This setting may affect the timing of SetInterval and SetTimeout calls.
Disable Ads Above The Fold - Above the fold is the content that a viewer sees before they scroll down the page. This feature tries to improve page performance and Core Web Vitals (FID, LCP) by removing ads above the fold. Can risk decreasing your revenue as these ad locations are usually the higher earning locations so only enable as a last resort.
jQuery Loading Method - jQuery is a Javascript library used by many web technologies, loading this library takes time so we attempt to optimize this in one of 2 ways:
Script delay can cause some issue with the following functionality:
There are some technologies that make optimizing your site with script delay difficult: