myithubau
Forum Replies Created
-
Forum: Plugins
In reply to: [Weight Based Shipping for WooCommerce] Object Cache on our siteNo update still?
Forum: Plugins
In reply to: [GTM Kit - Google Tag Manager & GA4 integration] Error in Checkout PageIt is related to GTM kit.
Yes thanks
After clearing cache its looking lot better.
Hi, I have added this code to functions.php but there has been no changes.
and where exactly do i need to add this code?
Do you mean in Child theme ?
Hi,
It has been 4 days since I am waiting for your response.
he LCP score is indeed mainly affected by the loading of JavaScript files, as you have pointed out earlier in the ticket. On your website that JavaScript code comes primarily from the Google Tag Manager implementation. You have a plugin named gtm-kit with which you load various analytics JavaScript code and about 85% of the JavaScript loading time is related to code brought through the Google Tag Manager:
https://www.myithub.com.au/Screenshot%202024-08-21%20at%2018.44.24.png
For the sake of testing purposes, I disabled temporarily the gtm-kit plugin and retested the mobile performance with the Google PageSpeed Insights too. As you can see from the results below, the mobile score was instantly increased to 73:
https://pagespeed.web.dev/analysis/https-www-myithub-com-au/qk9m8azo1y?form_factor=mobile
hi,
Its not fixed still.
The issue with your website are these scripts:Full-size image here: https://i.imgur.com/Dq57qZ0.png
Especially the GTM ones. And those scripts are being triggered by these inline scripts, which are being excluded from Delay JavaScript execution by adding the attribute data-nowprocket:
Full-size image here: https://i.imgur.com/whXoLKc.png
I will try to explain myself as clearly as possible:
For WP Rocket to be able to delay the execution of a script, that script must be present in the HTML of the page, only then WP Rocket can add the RocketLazyloadscript attribute to delay it, but if that script is not present in the HTML but is dynamically triggered (as in this case) by a script that was itself excluded from the feature, then WP Rocket will not be able to delay it and therefore that script will end up affecting your score if it consumes too much execution time.
Hi, I have updated your plugin and Wp rocket also, the issue seems to have fixed. Can you please recheck ?
hi Torben,
Please check response from WP Rocket
I’ve checked your website and seems to be there are some GTMkit scripts that are not being delayed, take a look:
The scripts on the red squares are not delayed:

Full-size image here: https://i.imgur.com/xI4T0Pd.png
Those scripts (which in turn are instantiating GTM scripts) are being excluded from Delay JavaScript execution because the
data-nowprocketattribute has been added to them:
Full-size image here: https://i.imgur.com/iiJlSJy.png
Further information in this article.
And this attribute it’s being added by GTMKit, in this function:

Full-size image here: https://i.imgur.com/QxaAmkw.png
that is what we are not able to understand since its delaying to load our site
Google Tag Manager tag-manager
1,688 ms
1,524 ms
109 ms- This reply was modified 1 year, 10 months ago by myithubau.
I have read the message and its already configured as per your recommendations –
load_delayed_js event is ONDelay JavaScript execution in ON in WP rocket.
What else are you proposing to change?hi,
I have just sent, Since we are on Woocommerce, Shall we need to Activate the WooCommerce integration also or its not mandatory.
Regards,