Expose a setting to make `updateVirtualDisplay()` not change the DOM

Use case or problem

I have several “article”-type notes, which have tens of thousands of words and hundreds of lines of text in dozens of paragraphs each. Some of those paragraphs are in callouts with the CSS float: right applied to them, as side bars, and some of them go on for multiple paragraphs and screen heights as well.

When I scroll down sufficiently past the place where those side bars are in the code, Obsidian removes them from the DOM even when they are still visible and affecting the layout, causing ugly rerendering of the page.

There’s a global(-ish) value in the code, obfuscated name AA, which is normally set to false. Setting it to true reliably causes the layout to stay consistent during scrolling.

In particular, the only result of setting it to true seems to be in making updateVirtualDisplay() return before changing the DOM structure, as seen in the beginning of the method:

                 if ("number" == typeof e && (a = e),
                AA) {
                    var s = [];
                    s.push(r);
                    for (var l = 0, c = o; l < c.length; l++) {
                        var u = c[l];
                        s.push(u.el)
                    }
                    return i.setChildrenInPlace(s),
                    i.style.minHeight = "",
                    r.style.marginBottom = "0",
                    void (n.scrollTop = a)
                }

Proposed solution

Expose the global variable AA as a setting. If there is one already, I couldn’t find it and I’m sorry for wasting your time.

Current workaround (optional)

Use the debug tools to change the global variable AA to true.