5 ms·
I love the idea of binary ASTs as the things browsers compile instead of source, but I don't think making browsers even more complex is worth it. These new bin
by dgreensp 9y ago
I love the idea of binary ASTs as the things browsers compile instead of source, but I don't think making browsers even more complex is worth it. These new binary files would also be yet another type of asset to serve alongside your .js files, with implications for debugging and source maps. If the reward is bloated SPAs load 10% faster, as long as they ship both JS and binary JS, forever, I would wonder if browsers should parse the binary format or just keep optimizing their text parsers more.
- paulddraper 9y agoThis seems pretty easy though. When you parse, you parse to the same JS AST. When you show it in the browser, you show the text form of the JS AST. Source maps like normal. It's a reasonably lightweight proposal, though IDK if it will be compelling enough.