q-proxyable
Version:
normal utils by qianzhixiang
33 lines (32 loc) • 917 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
var tslib_1 = require("tslib");
var decoraters_1 = require("./decoraters");
var A = (function () {
function A() {
this.a = 1;
}
A.prototype.b = function () {
console.log('b is called');
return this.a + 1;
};
A.prototype.show = function () {
this.a++;
};
tslib_1.__decorate([
decoraters_1.State(),
tslib_1.__metadata("design:type", Object)
], A.prototype, "a", void 0);
tslib_1.__decorate([
decoraters_1.Computed(),
tslib_1.__metadata("design:type", Function),
tslib_1.__metadata("design:paramtypes", []),
tslib_1.__metadata("design:returntype", void 0)
], A.prototype, "b", null);
return A;
}());
var a = new A();
console.log(a.b());
console.log(a.b());
a.show();
console.log(a.b());
;