This module provides some syntax sugar for "class" declarations, constructors, mixins, "super" calls and static members.
You can install using Node Package Manager (npm):
npm install inherit
It also supports RequireJS module format and YM module format.
Module has been tested in IE6+, Mozilla Firefox 3+, Chrome 5+, Safari 5+, Opera 10+.
Creating a base class
Creating a base class with static properties
Creating a derived class
Creating a derived class with mixins
var inherit = ;// base "class"var A =;// inherited "class" from Avar B =;// mixin Mvar M =;// inherited "class" from A with mixin Mvar C =;var instanceOfB = 'property';instanceOfB; // returns 'property of instanceB'instanceOfB; // returns 'AB'B; // returns 'staticA of staticB'var instanceOfC = ;instanceOfC // returns "mixed property from C"