What I have To do To Avoid Cumulative Layout Shift (CLS) On A Section? (SP Page Builder) - Question | JoomShaper
Black Friday sale is live with flat 50% OFF. Sale ends soon! Grab your deal now!

What I have To do To Avoid Cumulative Layout Shift (CLS) On A Section? (SP Page Builder)

Marco Lungo

Marco Lungo

SP Page Builder 3 years ago

Hi everybody, as in the image at the link https://drive.google.com/file/d/1Gv02VAVEkBlNEUPnasyFIhYujb0eOjID/view?usp=sharing, I've a huge CLS caused by (listening to Lighthouse) shift sections created by SP Page Builder. I do not undestand why and, in consequence of that, which correction I've to do.

Thank you!

0
15 Answers
Toufiq
Toufiq
Accepted Answer
Senior Staff 3 years ago #49861

Hi there,

Thanks for contacting us. Sorry for the inconvenience. I would request you to check this blog post.

https://web.dev/optimize-cls/

-Thanks

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #49881

Ciao,

you can also use JCH Optimzie Pro extension and use this feature.

foto_7489_2021.png

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #49915

Ciao Paul, I have installed JCH Pro but it causes problems on video (in some circumstances it disappear), distrortion of the images and so on. May I am not able to set correctly the component, but this is not the first time that I have renounced to use it. Thank You!

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #49939

In that case you have to contact with JCH Opt Pro developer. I am (we are) not offcial support of that tool.

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50119

Hi Paul, also, the big problem that JCH Optimize Pro gives me is that it greatly increases the Initial Server Response Time, making the optimization it brings completely in vain. Unfortunately I can't understand why it does this, with Joomla debugging it comes out quite clearly that the problem is JCH Optimize, but it seems strange to me that it happens to me that I have a dedicated server for only 10 low-access sites, based on Windows Server 2019, Apache and MariaDB. I have 32 GB of memory, so plenty of space. I have no idea what is wrong, maybe PHP: I also installed and activated APC but it has changed practically nothing. I wrote to JCH Optimize support, let's see what they say. However, the CLS problem does not go away with JCH Optimize, because it only affects images. Mine, on the other hand, is a problem of Sections generated by the template, and I can't find a solution to that. Do you have any ideas? Please try to do Lighthouse on www.consulenzalocali.it, you will see what caused the CLS. Thank you!

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #50156

In that case JCH Optimize is not recommended for you. Uninstall it. Hopefully, there are others speed up extensions.


About CLS - I am afraid that some addons code have to be customized to improve it. Some like Image addon Or Slideshow addon have image size settings. Do you know which addon makes the most problem?

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50169

Hi Paul, the strange thing is that, by disabling the various addons / rows that from time to time Lighthouse (as in the same way GTMetrix) indicate as contributions to the CLS, the element reported as having 0.782 (more or less) of contribution to the CLS, moves . Change, moving to the last enabled item. It seems that the problem is with the Indigo template, and I am starting to believe it because it is the only one that gives me these problems out of at least a dozen that I have in production. What do I have to tell you ... it's strange and I can't take cover. The problem of your access is probably related to a fact of checking the server. I use IPBan, and if for any reason your IP is even just on a blacklist, it won't let you through. Could you please do a whoami and give me your IP so I can check that it hasn't been banned? Thank you!

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #50174

You can make TEST with raw Helix Ultimate template as well.

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50182

Ah. Which is the way to do that?

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #50216

Download that template, it's free, install and set as default for 3minutes, to makes online tests on GTMetrix. Just to compare results.

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50236

Hi Paul, test done with Helix Ultimate template. Despite of a huge Page Speed result (100 on Desktop, 92 on Mobile, instead of 78 in Dektop and 52 on Mobile using Indigo template :-( ), the CLS situation is the same: https://drive.google.com/file/d/1ijWmps5hOq_N1DTw5T6NaoWr2fGMAbl4/view?usp=sharing

So, is this a problem of Page Builder?

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #50247

In that case, yes probably. In SPPB 3 we cannot do anything in that topic, but at least I will have oportunity to improve SPPB4 addons soon.

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50253

Sad to hear.... so, is there no way to correct this situation? Maybe a custom css to refer using the custom class of the addons could resolve the bug?

0
Paul Frankowski
Paul Frankowski
Accepted Answer
Senior Staff 3 years ago #50276

In theory you can set width and height of images by CSS if this same may help somehow. Read tips from 1st @Toufiq link.

0
Marco Lungo
Marco Lungo
Accepted Answer
3 years ago #50320

It does'n work. The problem is on the sections, not on the images. This appears as an entire section that provoke CLS and FOT. The section is particulary of that template, it seems, with an overlap on the previous section. Boh. I could say anything else.

0