4 ms·
Excellent article on Microsoft's journey of refactoring IE's DOM model. I actually felt sympathy reading how it all started with a linear text-based data struct
by lioeters 6y ago
Excellent article on Microsoft's journey of refactoring IE's DOM model. I actually felt sympathy reading how it all started with a linear text-based data structure, which must have seemed reasonable at the time. (In hindsight, a tree should have been the natural shape, and they should have been aware of parsers and ASTs. But can we blame them?) And how the layers of complexity were added, using parallel data structures that needed to be synced on every DOM operation.
By the time the article reached "Modernizing the DOM tree", I could just imagine the years of devs suffering that the whole architecture must have caused.
> According to an internal investigation, from IE7 to IE11, approximately 28% of all IE reliability bugs originated from code in core DOM components.
The second article is quite relevant too, how the C/C++ compiler used token streams instead of a real AST, until 2015! There are parallels to the above issue with the DOM model, how the original design of the data structure was inadequate, so they had to keep adding more layers of complexity. It's understandable how it happened, but makes me wonder if they should have had more experts in parsers/compilers during the design phase.
To give credit where due, both articles describe major successful refactorings of core design. I'm with you, that after learning about their struggles, I have more respect for developers at Microsoft.