Hacker News new | past | comments | ask | show | jobs | submit login

Which part of the HTML5 spec, though? A parser? Or the whole thing, including DOM APIs and all the features like media elements and so on?

Even an HTML5 parser is harder than it looks to implement to the level needed for a browser. You have to build a proper DOM, you have to be secure against all kinds of fuzzing, you have to implement off-main-thread parsing and speculative readahead for performance, you have integrate it correctly the HTML5 event loop for document.write() etc, you have to support innerHTML and so on.

Likewise building a JS engine is impressive, but I do not believe a Web-compatible competitive-performance JS engine can be built by any single person.




I feel like there's a tendency to put browser developers on a pedestal. Browsers are large and complicated, and no, a single person cannot write a browser competitive with Chrome from scratch. On the other hand, a single person can probably write a browser competitive with Dillo, if they are sufficiently motivated. Browser developers are just as competent and incompetent as other professional native programmers. There are several HTML5 parsers out there. JS engines are also relatively abundant, especially if you will settle for an interpreter. You can build such things yourself, too, if you have the time and want to hone your skills.


There's a huge amount of fairly boring work to write a DOM implementation (if you want half the APIs the web expects to work with the right semantics, you can't use an existing library), and layout is incredibly hard to get right (especially in a web compatible way). I think it's totally doable for a single person to do HTML + CSS2.1, with no scripting support, especially if you're happy to leverage existing libraries.

The big difference with most existing browser developers is the majority know a lot of the web platform inside out—but that's mostly a matter of having worked on an implementation for a long time and having to worry about edge-cases and interactions no web developer would ever think of. There's certainly a few who have achieved a huge amount for individual developers—but that's not a trait unique to the browser sphere.


The parser. Once for properly parsing HTML content, for a search engine, and the other for a framework used for saving pages (For an Instapaper like service). So it wasn't a big deal, but in both cases, a DOM was constructed and operations were executed against the DOM.

Nothing about that or the JS engine is impressive really. That was my point, more or less. Of course, there's a difference between building something that works, and something that works exceptionally works etc etc(all the stuff on top of that), but all told, I still don't think building a browser justifies assembling such a huge org, even if there is no reliance on third-party technologies.


Implementing an HTML parser is not hard—the spec is a book of instructions on what to do.

Implementing a fast HTML parser that will produce a fast DOM is a little harder.

Tying it in with a fast CSS engine is harder still.

Tying it in with a JavaScript engine is a bit more work as well.

Implementing layout is moderately fiendishly difficult to do and get right.

And it just gets harder the more of the web platform you add, and the more it has to be fast.


HTML5 parsing is maybe 1% of the HTML5 spec.




Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: