The Document Object Model roots
HTML was originally created to work from a distributed network with documents moving and editing across that network. This key concept slowly has evaporated from public consciousness that every view from the a HTML page has a Document Object Model underlying it. Key point to focus here is the Document
and from the beginning the system was built with distributed editors in place.
To see this behavior peek out from the past run this command in console
document.designMode = "on"
I have already enabled this mode on this page if you curious so change this text here