An open API service indexing awesome lists of open source software.

https://github.com/web-mech/gozen

Classes for Javascript
https://github.com/web-mech/gozen

Last synced: about 2 months ago
JSON representation

Classes for Javascript

Awesome Lists containing this project

README

        

Gozen
======
####A flexible javascript class system for node

I didn't like how most javascript class systems worked or how they were implemented, so I made Gozen.

######Example 1.

```
var Foo = new Class({
extend: true,
init: function(options) {
this.name = 'foo';
}
});

var foo = new Foo();

console.log(foo.name);
```
######Out:
```
foo
```

######Example 2.
```
var Bar = new Foo({
extend: true,
init: function(options) {
this._super.init.call(this, options);
this.name = this.name + options.name;
}
});

var bar = new Bar({name: ' bar'});

console.log(bar.name);
```

######Out:
```
foobar
```