welcome: please sign in

Please enter your password of your account at the remote wiki below.
/!\ You should trust both wikis because the password could be read by the particular administrators.

Clear message
location: ObjectOrientation

JavaScript does not specify a strict model for object oriented programming in the way that other languages you may be familiar with, like C++, Java, and Python do. Instead, JavaScript provides a suite of flexible tools from which you can do many different styles of OO as best suited for your particular application. Many parts of Conkeror are structured in a classical OO paradigm. This article describes the conventions that we adhere to in those parts of Conkeror.

function foo () {
    // base class initialization
foo.prototype = {
    constructor: foo,
    destroy: function () {}

function bar () {
    // derived class initialization
bar.prototype = {
    constructor: bar,
    __proto__: foo.prototype,
    destroy: function () {
        // derived class destruction