views:

34

answers:

1

A web-browser window contains the window object. This object contains many properties. Many of those properties are objects. Some are constructors (XMLHttpRequest, Worker, File, ...), some are regular objects (document, location, navigator, history, screen, ...), some are non-constructor functions (a.k.a. methods) (alert, setTimeout, ...). Then there are properties that just contain primitive values (innerHeight, innerWidth, name, status, closed, ...).

This is a huge collection of properties. Studying all of them is hard enough, but it becomes even more brutal when we consider that each browser has its own set of those properties.

Here are the window properties references for Firefox and IE:

Firefox: https://developer.mozilla.org/en/Gecko_DOM_Reference

IE: http://msdn.microsoft.com/en-us/library/ms533054(v=VS.85).aspx

(btw, don't get confused by the name "Gecko DOM Reference" - it is a complete browser objects reference and the DOM (the document object) is just a part of it)

I don't even know where the references for Webkit browsers or the Opera browser are...

I noticed that there is a "Comparison of layout engines" series on Wikipedia which covers HTML, CSS, the DOM, and others. But it lacks an article about browser objects (window object properies). I mean, how could a web-developer know which property is cross-browser? Does he have to test for each one of them?

I really would like to have a web-site that tracks (maintains) a cross-browser reference of window properties. Is there such a service?

+1  A: 

Maybe quirksmode?

Concerning the window object in particular check: the MDC and this.

Knu
Quirksmode is DOM and CSS. The DOM is only a part of the object tree in the browser. The DOM is also documented in the W3C standards, which makes it even less an issue. The main problem are: 1. the non-standardized objects, 2. the new stuff (the new standards like workers, sockets, geolocation, local storage...)
Šime Vidas
#1 is mostly covered by quirksmode http://www.quirksmode.org/sitemap.html - concerning #2 there's only one problem that i know of it's the web sql database vs indexdb issue http://hacks.mozilla.org/2010/06/comparing-indexeddb-and-webdatabase/
Knu
I am talking about a compatibility table of the properties of the global object (the window object) in the browsers. Quirksmode does not have such a thing.
Šime Vidas
you mean something like http://www.quirksmode.org/dom/w3c_cssom.html? - ill update my answer.
Knu
@vidas check my updated answer (sept 25)
Knu