Site logo

[Support request] Cumulative Layout Shift

Home Forums Support [Support request] Cumulative Layout Shift

Home Forums Support Cumulative Layout Shift

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #2435683
    Anil kumar

    I just put google ads under the title. Because of this my Cumulative Layout Shift problem is coming. Please solve this problem. Thank you

    #2436267
    Ying
    Staff
    Customer Support

    Can you share the link to the page where the ads been added?

    #2436809
    Anil kumar

    When I have placed ads below the entry title, then I am facing the problem of Cumulative Layout Shift.

    And another problem is that I have to put these ads below the entry meta. Means above the feature image.

    You can see an article below.

    website link

    #2436932
    David
    Staff
    Customer Support

    Hi there,

    the theme has no control over the spacing your adverts will occupy and if those adverts are inserted without first declaring the space they require then ti will cause CLS.

    The most we can suggest is to set a min-height on your ad containers.
    You can do that with this CSS:

    
    .adsbygoogle {
        min-height: 280px !important;
    }

    But i suggest you check with your ad provider for the correct code so it sets the height for you.

    #2437442
    Anil kumar

    problem fixed, thank you soo much David.

    Second problem, I want to show ads below entry meta and above feature image. Also I want to show this ad only in mobile. please tell me what i have to change in the hook.

    image link

    #2438037
    Fernando
    Customer Support

    Hi Anil,

    Can you open a new topic regarding this new problem?

    Hope to hear from you soon!

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.