Archived topic
Avoid an excessive DOM size 1,449 elements
1 reply · Started by Prajwal on June 22, 2021
Hi, This is related to the showing updated date instead of the date published!
Image attached and the link to the website too
Hi there,
this document explains what DOM Size diagnostics mean:
The issue you're being flagged on is the Total DOM Elements of 1449. ( the doc above states its an issue at 1500 - but its out of date - see here )
The maximum DOM Depth only gets flagged if it reaches 32. And the Element it lists is just the deepest nested element - that itself is not a problem and not anyway to related to that Diagnostic report being flagged as red.
Simple explanation of DOM Elements.
Every element - ie. text block, image, advert or other HTML you add to a post gets counted as DOM element. The only way to reduce that is to remove content from the page, or use Page Breaks to paginate the posts.
But its only a diganostic and has no direct effect on page speed scores - it only becomes a problem is you're using a lot oF CSS or JS on your page to create the layout. More DOM Elements * More code = greater processing time for the browser. If this were an issue you would most likely see CLS issues or poor rendering of the site when it is viewed.