mootools/Base — Issue #33: Should Host.install install generics
Author: arian
Created: 2011-10-21 21:24:05+00:00
State: open

See these comments on pull request #32 by @ibolmo

https://github.com/mootools/Base/pull/32#r183609
https://github.com/mootools/Base/pull/32#r183621

``` js
// to 1.4.js

require(['Utility/Array', ...], function(Array, ...){

Array.install();

});

// my.app.js

Array.forEach([], function(){

});

/* no need for require: */
require(['Utility/Array'], function(Array){

Array.forEach(...);

});
```

Currently these generics are not installed, because in your app it wouldn't matter much:

``` js
define(['Base/Host/Array'], function(HostArray){
HostArray.install();
// later
HostArray.forEach(…);
// vs.
Array.forEach(…);
});
```

So I'd say :-1: