How can i make a static encapsulation with self members in javascript?
such as in php:
class bar{
static public $foo;
static public function set() {
self::$foo = 'a';
}
}
bar::set();
In javascript:
var bar = function () {
????????
}
bar.set();
Thanks!
No comments:
Post a Comment