Model → DOM renderer. Structural sharing in the immutable document makes
diffing cheap: a child that is reference-equal to what an element already
shows is skipped; a same-type block is patched in place; anything else is
rebuilt. The mapping from DOM elements back to model nodes lives in a
WeakMap consumed by position mapping and selection sync.
Model → DOM renderer. Structural sharing in the immutable document makes diffing cheap: a child that is reference-equal to what an element already shows is skipped; a same-type block is patched in place; anything else is rebuilt. The mapping from DOM elements back to model nodes lives in a WeakMap consumed by position mapping and selection sync.