Performance and collapsed items like details / reveal widgets

Whilst investigating a performance hit I revisited discussions on the three similar functions which collapse content not currently required for viewing

  1. the native TW reveal widget
  2. the pure html details tag
  3. the Details plugin by telmiger which enhances the pure html details tag.

Discussion here… Details widget in core · Issue #3353 · TiddlyWiki/TiddlyWiki5 · GitHub

Almost every one of my 4000+ tiddlers has it’s content contained within the scope of a details tag (Telmiger’s version) - they are often paragraphs or even pages long with images and sometime videos and often I nest the details (I stopped using the reveal widget 2021 as it does not nest well).

So what I find myself increasingly asking pertains to the performance aspects of displayed and non-displayed content once a single file tiddlywiki has loaded.

I assume that tiddlers not in the storyriver list have a significantly reduced performance hit compared with when they are in the storyriver but also what about tiddlers that are in the storyriver list but are currently scrolled off screen?

What about the html display tag? Does it offer a similar performance advantage when closed?

Similarly the reveal widget?

I think these are fairly sensible questions for anyone with a large single file wiki to ask themselves - what layout choices and work practices will help mitigate performance cost of content I am not actively viewing at the current time?

Thanks in advance

Tiddler content is only rendered when it is “in the StoryRiver” (or perhaps in the SideBar)

The HTML details tag (and, by extension, the Details plugin) always render their content, while the $reveal widget only renders content when its state tiddler contains the appropriate value (e.g., type="nomatch" text=""). The exception is when the retain="yes" parameter is used, in which case that $reveal widget’s content is always rendered, even if not currently visible.

Note that the <<tabs>> macro uses the $reveal widget, so only the content of the currently displayed tab is rendered. This is why setting the SideBar tabs to something other than “Recent” can improve performance, since the Recent tab typically requires significantly more processing than say, the “Open” tab.

-e

Not an answer to your question but since you use details elements so much you might find my Subsume plugin handy The Subsume Plugin — Turn links into sliders!

Thanks for that Eric