add descriptor for all class properties - fixes #1235

This commit is contained in:
Sebastian McKenzie
2015-04-12 08:53:01 -07:00
parent 652d3c7320
commit 26b5174dfa
7 changed files with 48 additions and 19 deletions

View File

@@ -12,10 +12,14 @@ var Foo = (function () {
}
babelHelpers.createClass(Foo, [{
key: "bar",
value: undefined,
enumerable: true
}, {
key: "__initializeProperties",
value: function __initializeProperties() {
this.bar = foo;
}
}]);
return Foo;
})();
})();

View File

@@ -12,5 +12,10 @@ var Foo = (function (_Bar) {
}
babelHelpers.inherits(Foo, _Bar);
babelHelpers.createClass(Foo, [{
key: "bar",
value: undefined,
enumerable: true
}]);
return Foo;
})(Bar);
})(Bar);

View File

@@ -1,6 +1,15 @@
"use strict";
var Foo = function Foo() {
babelHelpers.classCallCheck(this, Foo);
this.bar = "foo";
};
var Foo = (function () {
function Foo() {
babelHelpers.classCallCheck(this, Foo);
this.bar = "foo";
}
babelHelpers.createClass(Foo, [{
key: "bar",
value: undefined,
enumerable: true
}]);
return Foo;
})();

View File

@@ -10,5 +10,10 @@ var Foo = (function (_Bar) {
}
babelHelpers.inherits(Foo, _Bar);
babelHelpers.createClass(Foo, [{
key: "bar",
value: undefined,
enumerable: true
}]);
return Foo;
})(Bar);
})(Bar);

View File

@@ -9,5 +9,10 @@ var Foo = (function (_Bar) {
}
babelHelpers.inherits(Foo, _Bar);
babelHelpers.createClass(Foo, [{
key: "bar",
value: undefined,
enumerable: true
}]);
return Foo;
})(Bar);
})(Bar);