There is no such thing like static class variables/properties in js. The simplest approach is just use the "class" function as a namespace for static variables.
It means, just access in Person.count directly.
You can use closures as well, but actually in 90% cases it will be overkill.
In modern browsers you also can redefine getter/setter function to wrap usage of Person.count and other "static" variables.
This snippet demonstrates the idea:
function borrow(obj, borrowobj, fname) {
obj.__defineGetter__(fname, function() {
return borrowobj[fname]
})
obj.__defineSetter__(fname, function(val) {
borrowobj[fname] = val
})
}
function Person() {
borrow(this, Person, "count");
this.count++
}
Person.count = 0;
new Person();
new Person();
var p = new Person();
alert(p.count);