Any serious candidate for an operating system is going to be complex. Personally I'm a little dismayed at current efforts to turn the browser into yet another cross-platform utopia. Some things will always be better native and pushing all this junk into the web browser just gets in the way of making basic things like a sane layout model that much more difficult.
First, JS & HTML are much more popular than Windows APIs. Second, I think johnrob meant that the DOM is more sane than most "desktop" APIs for laying out apps, not desktop publishing layouts.