HI Christian,
thanks for your answer on https://www.drupal.org/project/geolocation/issues/3204158, im sorry to reopen ist, because i realized it was closed before.
Can you tell me what is the reason for line <div data-views-row-index="0">...</div> and/or can get rid of them, because when I delete them from the DOM with Chrome DevTool the map works without any problem and I can't find similiar DOM-Elements in other leaflet (plugins) so far.

And @performance: Google Speedtest complains about to many DOM-Elements an tells me: A large DOM tree can slow down your page performance in multiple ways:

  • Network efficiency and load performance:: A large DOM tree often includes many nodes that aren't visible when the user first loads the page, which unnecessarily increases data costs for your users and slows down load time.
  • Runtime performance: As users and scripts interact with your page, the browser must constantly recompute the position and styling of nodes. A large DOM tree in combination with complicated style rules can severely slow down rendering.
  • Memory performance: If your JavaScript uses general query selectors such as document.querySelectorAll('li'), you may be unknowingly storing references to a very large number of nodes, which can overwhelm the memory capabilities of your users' devices.

Especially on mobile i experience these problems.
Thanks for your time and answer in advance!
pidru

Comments

pidru created an issue. See original summary.

christianadamski’s picture

Status: Active » Postponed (maintainer needs more info)

I understand that this really bothers you, but ai don't fully understand why. The number of DOM Elements shouldn't matter.

How many markers do you want to display?
And why are you unhappy? Is the site slow right now?
What exactly changes, when you remove that wrapping DOM Element you mention above?
Is there a publicly available link to your website?

christianadamski’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)