Since modern PCs ought to be able to lay out a conventional, non-JS page pretty quickly these days, then it does make some sense to design the whole browser around running JS as fast as possible with a layout engine attached, and hopefully that means designing in the whole ‘sandboxing’ functionality from the start, too.
Doing the whole JS engine from scratch is a bit crazy, tho. Parsing the JS into eg. Clang’s intermediate form, and then letting it compile it, seems a bit more sane.
Since modern PCs ought to be able to lay out a conventional, non-JS page pretty quickly these days, then it does make some sense to design the whole browser around running JS as fast as possible with a layout engine attached, and hopefully that means designing in the whole ‘sandboxing’ functionality from the start, too.
Doing the whole JS engine from scratch is a bit crazy, tho. Parsing the JS into eg. Clang’s intermediate form, and then letting it compile it, seems a bit more sane.