Your mistake is assuming there is some correlation with usefulness and size.
The JS Gmail UI from 15 years ago was just as functional as the one today.
Websites that are supposed to be simple lists end up bloated and laggy because of really poor JS that makes one request per item iteratively to populate a list.
I do like the old JS Gmail UI. But the current JS Gmail UI doesn’t feel any slower. It is cluttered with more features, but some of them I find useful. (Displaying my calendar and being able to accept invites right in Gmail being a big one.)