Skip to content
View application.controller.js
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
View mem-leak-monday.md

well its tuesday, but I was with family yesterday...

Late last week @cibernox reported that https://github.com/emberjs/ember.js/issues/11748 was still leaking for him. As it turns out, the main leak was forgetting to null out top levels vars in afterEach. But that kinda sucks, as it is tedious and error prone. So instead I wanted a better solution, one where the purden was not on the test writers. So, as it turns out we can also just release the ES2015 module after requiring it, allowing the JS GC to do the work for us.

The follow commits add the ability to unsee a module in the loader, and configure the test-loader to unsee after requiring.

View controllers.application.js
import Ember from 'ember';
Ember.Handlebars.helper('is-equal', function(a, b){
return a === b;
});
export default Ember.Controller.extend({
appName:'Ember Twiddle',
actions: {
View controllers.application.js
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
View broccoli-babel-transpiler.patch
diff --git a/index.js b/index.js
index 2ec4b85..d010a51 100644
--- a/index.js
+++ b/index.js
@@ -59,9 +59,9 @@ Babel.prototype = Object.create(Filter.prototype);
Babel.prototype.constructor = Babel;
Babel.prototype.targetExtension = ['js'];
-Babel.prototype.rebuild = function() {
+Babel.prototype.build = function() {
View controllers.application.js
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
View controllers.application.js
export default Ember.Controller.extend({
actions: {
changed(val) {
this.set('currentValue', val);
console.log(val);
}
}
});
View controllers.application.js
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
View args.js
function printStatus(fn) {
switch (%GetOptimizationStatus(fn)) {
case 1: console.log('Function is optimized'); break;
case 2: console.log('Function is not optimized'); break;
case 3: console.log('Function is always optimized'); break;
case 4: console.log('Function is never optimized'); break;
case 6: console.log('Function is maybe deoptimized'); break;
}
}
View foo.md

so given:

var a = {
  @myDecorator('someValue') name
};

if name is not defined, what should happen. Should it always throw, or only throw if myDecorator attempts to access descriptor.value?

Something went wrong with that request. Please try again.